Class Udp.Send
This message is understood by the "simple sender" which can be obtained by
sending the Udp.SimpleSender query to the Manager as well as by
the listener actors which are created in response to Udp.Bind. It will send
the given payload data as one UDP datagram to the given target address. The
UDP actor will respond with Udp.CommandFailed if the send could not be
enqueued to the O/S kernel because the send buffer was full. If the given
ack
is not of type Udp.NoAck the UDP actor will reply with the given
object as soon as the datagram has been successfully enqueued to the O/S
kernel.
The sending UDP socket’s address belongs to the "simple sender" which does not handle inbound datagrams and sends from an ephemeral port; therefore sending using this mechanism is not suitable if replies are expected, use Udp.Bind in that case.
Implements
Inherited Members
Namespace: Akka.IO
Assembly: Akka.dll
Syntax
public sealed class Send : Udp.Command, INoSerializationVerificationNeeded
Constructors
| Improve this Doc View SourceSend(ByteString, EndPoint, Udp.Event)
Creates a new send request to be executed via UDP socket to a addressed to the provided endpoint.
Once send completes, this request will acknowledged back on the sender side with an ack
object.
Declaration
public Send(ByteString payload, EndPoint target, Udp.Event ack)
Parameters
Type | Name | Description |
---|---|---|
ByteString | payload | Binary payload to be send. |
EndPoint | target | An endpoint of the message receiver. |
Udp.Event | ack | Acknowledgement send back to the sender, once |
Properties
| Improve this Doc View SourceAck
Acknowledgement send back to the sender, once Payload has been send through a socket. If it's Udp.NoAck, then no acknowledgement will be send.
Declaration
public Udp.Event Ack { get; }
Property Value
Type | Description |
---|---|
Udp.Event |
Payload
A binary payload to be send to the Target. It must fit into a single UDP datagram.
Declaration
public ByteString Payload { get; }
Property Value
Type | Description |
---|---|
ByteString |
Target
An endpoint, to which current Payload will be send.
Declaration
public EndPoint Target { get; }
Property Value
Type | Description |
---|---|
EndPoint |
WantsAck
Flag determining is a message sender is interested in receving send acknowledgement.
Declaration
public bool WantsAck { get; }
Property Value
Type | Description |
---|---|
Boolean |
Methods
| Improve this Doc View SourceCreate(ByteString, EndPoint)
Creates a new send request to be executed via UDP socket to a addressed to the provided endpoint. Once send completes, this request will not be acknowledged on by the sender side.
Declaration
public static Udp.Send Create(ByteString data, EndPoint target)
Parameters
Type | Name | Description |
---|---|---|
ByteString | data | Binary payload to be send. |
EndPoint | target | An endpoint of the message receiver. |
Returns
Type | Description |
---|---|
Udp.Send | TBD |
ToString()
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
String |