TcpConnectInfo

Namespace: inet

class TcpConnectInfo

Sent with message kind TCP_I_ESTABLISHED, to let the app know about the local and remote IP address and port.

See also: TcpCommandCode, ITcp

Usage diagram

Inheritance diagram

Extends

Name

Type

Description

TcpCommand

class

Control info for TCP connections. This class is to be set as control info (see cMessage::setControlInfo()) on all messages exchanged between TCP and application, in both directions. Some commands and indications (TCP_C_OPEN_xxx, TCP_I_STATUS) use subclasses.

Fields

Name

Type

Description

userId

int

id than can be freely used by the app

localAddr

L3Address

remoteAddr

L3Address

localPort

int

remotePort

int

autoRead

bool

true: TCP send up arrived data automatically. false: should use read command.

Source code

//
// Sent with message kind TCP_I_ESTABLISHED, to let the app know
// about the local and remote IP address and port.
//
// @see ~TcpCommandCode, ~ITcp
//
class TcpConnectInfo extends TcpCommand
{
    L3Address localAddr;
    L3Address remoteAddr;
    int localPort;
    int remotePort;
    bool autoRead;   // true: TCP send up arrived data automatically. false: should use read command.
}

File: src/inet/transportlayer/contract/tcp/TcpCommand.msg