UDPPacket

Namespace inet

UDPPacket

packet

Represents an UDP packet, to be used with the UDP module.

Fields

Name Type Description
srcPort unsigned short
destPort unsigned short
byteLength
totalLengthField int -1 means: getTotalLengthField() uses getByteLength()

Source code

//
// Represents an UDP packet, to be used with the ~UDP module.
//
packet UDPPacket
{
    @customize(true);
    unsigned short srcPort;
    unsigned short destPort;
    byteLength = UDP_HEADER_BYTES;
    int totalLengthField = -1;   // -1 means: getTotalLengthField() uses getByteLength()
}

File: src/inet/transportlayer/udp/UDPPacket.msg