![]() |
MAK RTIspy API Documentation for HLA 1.3
|
Stores the information on an RTI connection known by the Assistant. More...
Collaboration diagram for DtRtiConnectionInfo:Public Member Functions | |
| DtRtiConnectionInfo () | |
| Constructor. | |
| DtRtiConnectionInfo (const MAKRti::DtString &hostname, const MAKRti::DtInetAddr &publicAddr, const MAKRti::DtInetAddr &tcpAddress, int tcpPort, const MAKRti::DtInetAddr &udpAddress, int udpPort, const MAKRti::DtInetAddr &udpInterfaceAddr, int forwarderPort) | |
| rtiexec connection constructors | |
| DtRtiConnectionInfo (const MAKRti::DtInetAddr &publicAddr, const MAKRti::DtInetAddr &tcpAddress, int tcpPort, const MAKRti::DtInetAddr &udpAddress, int udpPort, const MAKRti::DtInetAddr &udpInterfaceAddr, int forwarderPort) | |
| DtRtiConnectionInfo (const MAKRti::DtInetAddr &publicAddr, const MAKRti::DtInetAddr &udpAddress, int port, const MAKRti::DtInetAddr &udpInterfaceAddr) | |
| Lightweight connection constructor. | |
| DtRtiConnectionInfo (const DtHostNameAddress &host, const MAKRti::DtInetAddr &publicAddr, int tcpPort, const MAKRti::DtInetAddr &udpAddress, int udpPort, const MAKRti::DtInetAddr &udpInterfaceAddr, bool useRtiexec, int forwarderPort) | |
| Constructor to set all values explicitly. | |
| virtual | ~DtRtiConnectionInfo () |
| Destructor. | |
| virtual bool | operator< (const DtRtiConnectionInfo &other) const |
| Less than operator. | |
| virtual bool | operator== (const DtRtiConnectionInfo &other) const |
| Equals operator. | |
| virtual bool | operator!= (const DtRtiConnectionInfo &other) const |
| Not equals operator. | |
| virtual DtRtiConnectionInfo & | operator= (const DtRtiConnectionInfo &other) |
| Assignment operator. | |
| virtual bool | isEquivalentHost (const DtRtiConnectionInfo &other) const |
| Determines if another connection has an equivalent host, based on the IP address and host name and network interface address. | |
| virtual bool | isEquivalentHostAllInterfaces (const DtRtiConnectionInfo &other) const |
| Determines if another connection has an equivalent host, based on the IP address and host name, assuming the host is bound on all interfaces. | |
| virtual bool | isEquivalentLightweight (const DtRtiConnectionInfo &other) const |
| Determines if another connection has equivalent UDP address and port. | |
| virtual bool | isLocalHost () const |
| Determines if the host for this connection is the local machine, based on the IP address and host name. | |
| virtual bool | conflictsWith (const DtRtiConnectionInfo &other, MAKRti::DtString &reason) const |
| Returns true if the connection conflicts with this connection and sets a description of the reason for the conflict. | |
| virtual MAKRti::DtString | defaultName () const |
| Default name for this connection. | |
| virtual MAKRti::DtString | description () const |
| Returns a text description of this connection. | |
| virtual MAKRti::DtString | hostName () const |
| Returns host name. | |
| virtual void | setHostName (const MAKRti::DtString &host, bool skipLookup=false) |
| Sets the host name. | |
| virtual void | setHostName (const MAKRti::DtString &host, const DtInetAddr &newIp) |
| Sets the hostname and IP without using a resolver (lookup) | |
| virtual const DtHostNameAddress & | hostNameAddress () const |
| Return the host name and address (TCP IP address) | |
| virtual const MAKRti::DtInetAddr & | tcpAddress () const |
| Returns TCP IP address for reliable communication. | |
| virtual void | setTcpAddress (const MAKRti::DtInetAddr &ip) |
| Sets the TCP IP address for reliable communication. | |
| virtual int | tcpPort () const |
| Returns TCP port. | |
| virtual void | setTcpPort (int port) |
| Sets the TCP port. | |
| virtual const MAKRti::DtInetAddr & | udpAddress () const |
| Returns UDP IP address for best effort communication. | |
| virtual void | setUdpAddress (const MAKRti::DtInetAddr &ip) |
| Sets the UDP IP address for best effort communication. | |
| virtual int | udpPort () const |
| Returns UDP port. | |
| virtual void | setUdpPort (int port) |
| Sets the UDP port. | |
| virtual const MAKRti::DtInetAddr & | udpInterfaceAddr () const |
| Returns the UDP interface address to use for this connection. | |
| virtual void | setUdpInterfaceAddr (const MAKRti::DtInetAddr &addr) |
| Sets the UDP interface address to use for this connection. | |
| virtual bool | useRtiexec () const |
| Returns whether this connection uses an rtiexec. | |
| virtual void | setUseRtiexec (bool useExec) |
| Sets whether this connection uses an rtiexec. | |
| virtual int | forwarderPort () const |
| Returns the forwarder port. | |
| virtual void | setForwarderPort (int port) |
| Sets the port. | |
| virtual bool | isValid () const |
| Returns true if this connection info passes a basic validity check. | |
| virtual MAKRti::DtString | hostPort () const |
| Get a string containing the host:forwarderPort. | |
| virtual const MAKRti::DtInetAddr & | localTcpInterfaceAddr () const |
| Returns the local TCP interface address to use for this connection. | |
| virtual void | setLocalTcpInterfaceAddr (const MAKRti::DtInetAddr &addr) |
| Sets the TCP interface address to use for this connection. | |
| virtual const MAKRti::DtInetAddr & | localUdpInterfaceAddr () const |
| Returns the local UDP interface address to use for this connection. | |
| virtual void | setLocalUdpInterfaceAddr (const MAKRti::DtInetAddr &addr) |
| Sets the UDP interface address to use for this connection. | |
| virtual void | setIsRoutesFileBased (bool val) |
| virtual bool | isRoutesFileBased () const |
| virtual void | print (DtOutputStream &os=DtInfo) const |
| Print the contents of this instance. | |
| virtual void | setPublicAddress (const MAKRti::DtInetAddr &publicAddr) |
| Sets the public address. | |
| virtual const MAKRti::DtInetAddr & | publicAddress () const |
| Returns the public address. | |
Static Public Member Functions | |
| static const DtRtiConnectionInfo & | invalidConn () |
| Returns an invalid connection. | |
| static void | setLocalIpAddresses (bool reset=false) |
| Sets the list of recognized local IP addresses. | |
| static const DtInetAddrSet & | localIpAddresses () |
| Returns list of local IP addresses. | |
| static bool | localSupportsIPv4 (bool reset=false) |
| Returns whether any of the local interfaces support IPv4. | |
| static bool | localSupportsIPv6 (bool reset=false) |
| Returns whether any of the local interfaces support IPv6. | |
| static MAKRti::DtString | constructConnName (const DtHostNameAddress &hostAddr, int tcpPort, const MAKRti::DtInetAddr &udpAddress, int udpPort, const MAKRti::DtInetAddr &udpInterfaceAddr, bool useRtiexec, int forwarderPort) |
| Constructs the default connection name using the given parameters. | |
| static MAKRti::DtString | constructConnDescription (const DtHostNameAddress &hostAddr, int tcpPort, const MAKRti::DtInetAddr &udpAddress, int udpPort, const MAKRti::DtInetAddr &udpInterfaceAddr, bool useRtiexec, int forwarderPort, const MAKRti::DtInetAddr &localTcpInterfaceAddr, const MAKRti::DtInetAddr &localUdpInterfaceAddr) |
| Constructs the connection description text using the given parameters. | |
| static MAKRti::DtString | hostPort (const MAKRti::DtString &host, int port) |
| Construct a host:port string. | |
| static const MAKRti::DtInetAddr & | defaultTcpAddress () |
| Returns the default parameters. | |
| static const MAKRti::DtInetAddr & | defaultUdpAddress () |
| Returns the default parameters. | |
| static int | defaultLightweightPort () |
| Returns the default parameters. | |
| static int | defaultRtiexecPort () |
| Returns the default parameters. | |
| static const MAKRti::DtString & | defaultHostName () |
| Returns the default parameters. | |
| static const MAKRti::DtInetAddr & | defaultTcpInterfaceAddr () |
| Returns the default parameters. | |
| static const MAKRti::DtInetAddr & | defaultUdpInterfaceAddr () |
| Returns the default parameters. | |
| static int | defaultForwarderPort () |
| Returns the default parameters. | |
Static Protected Member Functions | |
| static DtInetAddrSet & | theLocalIpAddresses () |
| Returns a reference to a static map of local IP addresses to netmasks. | |
Protected Attributes | |
| DtHostNameAddress | myHostNameAddress |
| Host of the rtiexec or forwarder (TCP IP) | |
| int | myTcpPort |
| TCP port for the connection. | |
| MAKRti::DtInetAddr | myUdpAddress |
| UDP IP address for best effort transport. | |
| int | myUdpPort |
| UDP port for the connection. | |
| MAKRti::DtInetAddr | myUdpInterfaceAddr |
| UDP interface address to use for this connection on host machine. | |
| MAKRti::DtInetAddr | myLocalTcpInterfaceAddr |
| TCP interface address to use for this connection on local machine. | |
| bool | myLocalTcpInterfaceAddrIsSet |
| MAKRti::DtInetAddr | myLocalUdpInterfaceAddr |
| UDP interface address to use for this connection on local machine. | |
| bool | myLocalUdpInterfaceAddrIsSet |
| bool | myUseRtiexec |
| Whether or not an rtiexec should be used. | |
| int | myForwarderPort |
| The port used by the forwarder to connect to other forwarders. | |
| bool | myIsRoutesFileBased |
| MAKRti::DtInetAddr | myPublicAddress |
| Public IP address. | |
Stores the information on an RTI connection known by the Assistant.
| DtRtiConnectionInfo::DtRtiConnectionInfo | ( | ) |
Constructor.
| DtRtiConnectionInfo::DtRtiConnectionInfo | ( | const MAKRti::DtString & | hostname, |
| const MAKRti::DtInetAddr & | publicAddr, | ||
| const MAKRti::DtInetAddr & | tcpAddress, | ||
| int | tcpPort, | ||
| const MAKRti::DtInetAddr & | udpAddress, | ||
| int | udpPort, | ||
| const MAKRti::DtInetAddr & | udpInterfaceAddr, | ||
| int | forwarderPort | ||
| ) |
rtiexec connection constructors
| DtRtiConnectionInfo::DtRtiConnectionInfo | ( | const MAKRti::DtInetAddr & | publicAddr, |
| const MAKRti::DtInetAddr & | tcpAddress, | ||
| int | tcpPort, | ||
| const MAKRti::DtInetAddr & | udpAddress, | ||
| int | udpPort, | ||
| const MAKRti::DtInetAddr & | udpInterfaceAddr, | ||
| int | forwarderPort | ||
| ) |
| DtRtiConnectionInfo::DtRtiConnectionInfo | ( | const MAKRti::DtInetAddr & | publicAddr, |
| const MAKRti::DtInetAddr & | udpAddress, | ||
| int | port, | ||
| const MAKRti::DtInetAddr & | udpInterfaceAddr | ||
| ) |
Lightweight connection constructor.
| DtRtiConnectionInfo::DtRtiConnectionInfo | ( | const DtHostNameAddress & | host, |
| const MAKRti::DtInetAddr & | publicAddr, | ||
| int | tcpPort, | ||
| const MAKRti::DtInetAddr & | udpAddress, | ||
| int | udpPort, | ||
| const MAKRti::DtInetAddr & | udpInterfaceAddr, | ||
| bool | useRtiexec, | ||
| int | forwarderPort | ||
| ) |
Constructor to set all values explicitly.
|
virtual |
Destructor.
|
virtual |
Returns true if the connection conflicts with this connection and sets a description of the reason for the conflict.
|
static |
Constructs the connection description text using the given parameters.
|
static |
Constructs the default connection name using the given parameters.
|
static |
Returns the default parameters.
|
static |
Returns the default parameters.
|
static |
Returns the default parameters.
|
virtual |
Default name for this connection.
|
static |
Returns the default parameters.
|
static |
Returns the default parameters.
|
static |
Returns the default parameters.
|
static |
Returns the default parameters.
|
static |
Returns the default parameters.
|
virtual |
Returns a text description of this connection.
|
virtual |
Returns the forwarder port.
Referenced by DtAssistantFederationsInfoMgr::cmpConnectionWithoutLocalIntf::operator()().
|
virtual |
Returns host name.
|
virtual |
Return the host name and address (TCP IP address)
Referenced by DtAssistantFederationsInfoMgr::cmpConnectionWithoutLocalIntf::operator()().
|
virtual |
Get a string containing the host:forwarderPort.
|
static |
Construct a host:port string.
|
static |
Returns an invalid connection.
|
virtual |
Determines if another connection has an equivalent host, based on the IP address and host name and network interface address.
|
virtual |
Determines if another connection has an equivalent host, based on the IP address and host name, assuming the host is bound on all interfaces.
|
virtual |
Determines if another connection has equivalent UDP address and port.
|
virtual |
Determines if the host for this connection is the local machine, based on the IP address and host name.
|
inlinevirtual |
|
virtual |
Returns true if this connection info passes a basic validity check.
|
inlinestatic |
Returns list of local IP addresses.
References theLocalIpAddresses().
|
static |
Returns whether any of the local interfaces support IPv4.
|
static |
Returns whether any of the local interfaces support IPv6.
|
virtual |
Returns the local TCP interface address to use for this connection.
|
virtual |
Returns the local UDP interface address to use for this connection.
|
virtual |
Not equals operator.
|
virtual |
Less than operator.
Comparisons are based on the following parameters in the order listed: 1) Lightweight connections are "less than" rtiexec connections 2) For lightweight connections: UDP IP and port 3) For rtiexec connections: host name or IP address (host name is used if available, though it is resolved to an IP and that is used as the actual value for comparison), TCP port, UDP port, UDP IP, forwarder port
|
virtual |
Assignment operator.
If the connections have equivalent hosts and the host name is already set, it will not be overwritten.
|
virtual |
Equals operator.
|
virtual |
Print the contents of this instance.
|
virtual |
Returns the public address.
|
virtual |
Sets the port.
|
virtual |
Sets the host name.
|
virtual |
Sets the hostname and IP without using a resolver (lookup)
|
inlinevirtual |
|
static |
Sets the list of recognized local IP addresses.
If the set of local IP addresses has already been created it will not be reset unless the reset flag is true.
|
virtual |
Sets the TCP interface address to use for this connection.
|
virtual |
Sets the UDP interface address to use for this connection.
|
virtual |
Sets the public address.
|
virtual |
Sets the TCP IP address for reliable communication.
|
virtual |
Sets the TCP port.
|
virtual |
Sets the UDP IP address for best effort communication.
|
virtual |
Sets the UDP interface address to use for this connection.
|
virtual |
Sets the UDP port.
|
virtual |
Sets whether this connection uses an rtiexec.
|
virtual |
Returns TCP IP address for reliable communication.
|
virtual |
Returns TCP port.
Referenced by DtAssistantFederationsInfoMgr::cmpConnectionWithoutLocalIntf::operator()().
|
staticprotected |
Returns a reference to a static map of local IP addresses to netmasks.
This is a shallow wrapper function which is provided to guarantee the std::map is initialized. Please note that this class is only used by the assistant, which is single threaded. If this class is ever used by a multithreaded application, this static member should be mutex protected.
Referenced by localIpAddresses().
|
virtual |
Returns UDP IP address for best effort communication.
Referenced by DtAssistantFederationsInfoMgr::cmpConnectionWithoutLocalIntf::operator()().
|
virtual |
Returns the UDP interface address to use for this connection.
|
virtual |
Returns UDP port.
Referenced by DtAssistantFederationsInfoMgr::cmpConnectionWithoutLocalIntf::operator()().
|
virtual |
Returns whether this connection uses an rtiexec.
Referenced by DtAssistantFederationsInfoMgr::cmpConnectionWithoutLocalIntf::operator()().
|
protected |
The port used by the forwarder to connect to other forwarders.
|
protected |
Host of the rtiexec or forwarder (TCP IP)
|
protected |
|
protected |
TCP interface address to use for this connection on local machine.
|
protected |
|
protected |
UDP interface address to use for this connection on local machine.
|
protected |
|
protected |
Public IP address.
|
protected |
TCP port for the connection.
|
protected |
UDP IP address for best effort transport.
|
protected |
UDP interface address to use for this connection on host machine.
|
protected |
UDP port for the connection.
|
protected |
Whether or not an rtiexec should be used.