TCPCommand

Namespace inet

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.

connId identifies the connection locally within the application (internally, TCP uses the (app gate index, connId) pair to identify the socket). connId is to be chosen by the application in the open command.

See also: TcpCommandCode, TcpStatusInd, TCPOpenCommand, TCPStatusInfo, ITCP

Extends

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

Fields

Name Type Description
connId int

identifies the socket within the application

userId int

id than can be freely used by the app

Source code

//
// 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.
//
// connId identifies the connection locally within the application (internally,
// TCP uses the (app gate index, connId) pair to identify the socket).
// connId is to be chosen by the application in the open command.
//
//# TODO explain userId
//
// @see ~TcpCommandCode, ~TcpStatusInd, ~TCPOpenCommand, ~TCPStatusInfo, ~ITCP
//
class TCPCommand extends cObject
{
    int connId = -1;   // identifies the socket within the application
    int userId = -1;   // id than can be freely used by the app
}


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