UdpJoinMulticastGroupsCommand

Namespace: inet

class UdpJoinMulticastGroupsCommand

Control info for letting an UDP socket join multicast groups. To set the option, send a message to the Udp module with kind=UDP_C_SETOPTION and an and instance of this control info class attached.

The address-interfaceId pairs are passed as two separate arrays. When there are less interfaceIds than multicast addresses, then -1 is assumed (meaning join on all interfaces).

See also: UdpCommandCode

Usage diagram

Inheritance diagram

Extends

Name

Type

Description

UdpSetOptionCommand

class

Base class for UDP socket option control info classes.

Fields

Name

Type

Description

optionCode

UdpSetOptionSubcode

optionCode

multicastAddr

L3Address[]

interfaceId

int[]

Source code

//
// Control info for letting an UDP socket join multicast groups.
// To set the option, send a message to the ~Udp module with kind=UDP_C_SETOPTION
// and an and instance of this control info class attached.
//
// The address-interfaceId pairs are passed as two separate arrays.
// When there are less interfaceIds than multicast addresses,
// then -1 is assumed (meaning join on all interfaces).
//
// @see ~UdpCommandCode
//
class UdpJoinMulticastGroupsCommand extends UdpSetOptionCommand
{
    optionCode = UDP_C_SETOPTION_JOIN_MCAST_GRP;
    L3Address multicastAddr[];
    int interfaceId[];
}

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