UdpConnectCommand

Namespace inet

UdpConnectCommand

class

Control info for connecting an UDP socket. To connect a socket, send a message to the Udp module with kind=UDP_C_CONNECT and an UdpConnectCommand attached. If the socket does not exist, it will be created.

Both the address and the port must be filled in.

See also: UdpCommandCode

Extends

Name Type Description
UdpControlInfo (unknown -- not in documented files)

Fields

Name Type Description
remoteAddr L3Address
remotePort int

Source code

//
// Control info for connecting an UDP socket. To connect a socket,
// send a message to the ~Udp module with kind=UDP_C_CONNECT and an
// ~UdpConnectCommand attached. If the socket does not exist,
// it will be created.
//
// Both the address and the port must be filled in.
//
// @see ~UdpCommandCode
//
class UdpConnectCommand extends UdpControlInfo
{
    L3Address remoteAddr;
    int remotePort = -1;
}

//
// Control info for sending data via UDP. To send a packet, send it to
// the ~Udp module with kind=UDP_C_SEND and an ~UDPSendCommand attached.
//
// UDP_C_SEND/~UDPSendCommand models both the Unix send() and sendto() calls.
// If the socket is connected, tags not required, or destAddr/destPort may be left blank (send()),
// otherwise it must contain the destination for the packet (sendto()).
//
// @see ~UdpCommandCode, ~PortsReq, ~L3AddressReq, ~InterfaceReq
//

File: src/inet/transportlayer/contract/udp/UdpControlInfo.msg