MAK RTIspy API Documentation for HLA Evolved
List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes
DtRtiExecHandshakeProcessor Class Reference

The DtRtiExecHandshakeProcessor class consists of filters for RtiExecHandshake messages for all three ports of a forwarder node. More...

+ Collaboration diagram for DtRtiExecHandshakeProcessor:

Classes

class  PendingRequest
 Simple helper class to hold status of pending rtiexec Handshakes. More...

Public Types

typedef bool(DtRtiExecHandshakeProcessor::* HandshakeMsgHandlerMemberCb )(const DtInetAddrAndPort &src, const DtRtiExecHandshakeMsg &msg)
 Pointer to member function callbacks used by the port filters.
typedef bool(DtRtiExecHandshakeProcessor::* DestinationProcessingMemberCb )(const DtInetAddrAndPort &src, DtForwarderPort::DtAddressPortList &destinations)

Public Member Functions

 DtRtiExecHandshakeProcessor (DtBoost::shared_ptr< DtForwarderNode > parent)
 Default Ctor.
virtual ~DtRtiExecHandshakeProcessor ()
 Default Dtor.
virtual bool gotMsgToLanPort (const DtInetAddrAndPort &src, const DtRtiExecHandshakeMsg &msg)
 Got Handshake Message from the IN Port to the LAN Port.
virtual bool gotMsgToOutPort (const DtInetAddrAndPort &src, const DtRtiExecHandshakeMsg &msg)
 Got Handshake Message from the IN or LAN Port to the OUT Port.
virtual bool gotRtiExecConnect (const DtInetAddrAndPort &src, const DtRtiExecConnectMsg &msg)
 Got rtiexec Connect Message from the IN or LAN Port.
virtual bool gotRtiExecDisconnect (const DtInetAddrAndPort &src, const DtRtiExecDisconnectMsg &msg)
 Got rtiexec Disconnect Message from the IN or LAN Port.
virtual bool processExecHandshakeDestinations (const DtInetAddrAndPort &src, DtForwarderPort::DtAddressPortList &destinations)
 Set forwarding destination list based on source (eg.
virtual bool ignoreExecHandshakeDestinations (const DtInetAddrAndPort &src, DtForwarderPort::DtAddressPortList &destinations)
 Exec Handshakes messages are simply forwarded to all LAN destinations.
virtual bool ignoreExecConnectDestinations (const DtInetAddrAndPort &src, DtForwarderPort::DtAddressPortList &destinations)
 Exec Connect messages are not forwarded by this processor, but they are also handled by the Forwarder Fault Processor which may forward them.
virtual bool isLocalGroupMember (const DtInetAddrAndPort &addr)
 Aids to determine inbound and outbound connections to rtiexec.
virtual DtInetAddrAndPort locateGroupPortal (const DtInetAddrAndPort &addr)
virtual DtInetAddrAndPort localNodeAddress ()
 Return parent node address.

Static Public Member Functions

static int lostConnection (const MAKRti::DtString &connName, unsigned int connID, const DtInetAddrAndPort &connAddr, void *usr)
 Connection loss callback.

Protected Types

typedef std::set< unsigned int > DtConnIdList
typedef std::map< unsigned int,
PendingRequest
DtConnIdToRequestMap

Protected Member Functions

virtual int lostConnection (const MAKRti::DtString &connName, unsigned int connID, const DtInetAddrAndPort &connAddr)
 Connection loss callback.
virtual void sendResponseMsg (DtRtiExecHandshakeMsg::DtHandshakeStatus status, DtHandle src, DtHandle dest, const MAKRti::DtString &hostName, bool fullyCompliant, const DtInetAddrAndPort *addr=0)
 Send a handshake Response based on aggregating all Local responses and all downstream WAN responses.
virtual bool processInToOutMsg (const DtInetAddrAndPort &src, const DtRtiExecHandshakeMsg &msg)
 Got Handshake Message from the IN Port to the OUT Port.
virtual bool processLanToOutMsg (const DtInetAddrAndPort &src, const DtRtiExecHandshakeMsg &msg)
 Got Handshake Message from the LAN Port to the OUT Port.

Protected Attributes

DtBoost::shared_ptr
< DtForwarderNode
myParent
DtRtiExecHandshakeFiltermyMsgToLanFilter
DtRtiExecHandshakeFiltermyMsgToOutFilter
DtRtiExecConnectionFilter
< DtRtiExecHandshakeProcessor > * 
myRtiExecConnectionFilter
DtConnIdList myLocalRtiExecConnIds
 List of local rtiexec Candidates.
DtConnIdToRequestMap myPendingRequests
 Map of outstanding rtiexec Requests to Responses.
unsigned long myConnectionIdOfLocalRtiExec
 If valid, this represents the connID of a local exec.
bool myHaveConnectionIdOfLocalRtiExec

Detailed Description

The DtRtiExecHandshakeProcessor class consists of filters for RtiExecHandshake messages for all three ports of a forwarder node.

The processor pulls all handshake messages passing through the forwarder node out of the message stream, and determines the appropriate response. The processor then generates the response and sends it to all necessary destinations.

Member Typedef Documentation

typedef bool(DtRtiExecHandshakeProcessor::* DtRtiExecHandshakeProcessor::DestinationProcessingMemberCb)(const DtInetAddrAndPort &src, DtForwarderPort::DtAddressPortList &destinations)
typedef std::set< unsigned int > DtRtiExecHandshakeProcessor::DtConnIdList
protected
typedef std::map< unsigned int, PendingRequest > DtRtiExecHandshakeProcessor::DtConnIdToRequestMap
protected
typedef bool(DtRtiExecHandshakeProcessor::* DtRtiExecHandshakeProcessor::HandshakeMsgHandlerMemberCb)(const DtInetAddrAndPort &src, const DtRtiExecHandshakeMsg &msg)

Pointer to member function callbacks used by the port filters.

Constructor & Destructor Documentation

DtRtiExecHandshakeProcessor::DtRtiExecHandshakeProcessor ( DtBoost::shared_ptr< DtForwarderNode parent)
DtRtiExecHandshakeProcessor::~DtRtiExecHandshakeProcessor ( )
virtual

Member Function Documentation

bool DtRtiExecHandshakeProcessor::gotMsgToLanPort ( const DtInetAddrAndPort src,
const DtRtiExecHandshakeMsg msg 
)
virtual
bool DtRtiExecHandshakeProcessor::gotMsgToOutPort ( const DtInetAddrAndPort src,
const DtRtiExecHandshakeMsg msg 
)
virtual

Got Handshake Message from the IN or LAN Port to the OUT Port.

References localNodeAddress(), DtRtiMsg::print(), processInToOutMsg(), and processLanToOutMsg().

Referenced by DtRtiExecHandshakeProcessor().

bool DtRtiExecHandshakeProcessor::gotRtiExecConnect ( const DtInetAddrAndPort src,
const DtRtiExecConnectMsg msg 
)
virtual
bool DtRtiExecHandshakeProcessor::gotRtiExecDisconnect ( const DtInetAddrAndPort src,
const DtRtiExecDisconnectMsg msg 
)
virtual
bool DtRtiExecHandshakeProcessor::ignoreExecConnectDestinations ( const DtInetAddrAndPort src,
DtForwarderPort::DtAddressPortList destinations 
)
virtual

Exec Connect messages are not forwarded by this processor, but they are also handled by the Forwarder Fault Processor which may forward them.

Referenced by DtRtiExecHandshakeProcessor().

bool DtRtiExecHandshakeProcessor::ignoreExecHandshakeDestinations ( const DtInetAddrAndPort src,
DtForwarderPort::DtAddressPortList destinations 
)
virtual

Exec Handshakes messages are simply forwarded to all LAN destinations.

This method is just a dummy for the filter ctor.

Referenced by DtRtiExecHandshakeProcessor().

bool DtRtiExecHandshakeProcessor::isLocalGroupMember ( const DtInetAddrAndPort addr)
virtual

Aids to determine inbound and outbound connections to rtiexec.

References myParent.

DtInetAddrAndPort DtRtiExecHandshakeProcessor::localNodeAddress ( )
virtual
DtInetAddrAndPort DtRtiExecHandshakeProcessor::locateGroupPortal ( const DtInetAddrAndPort addr)
virtual

References myParent.

int DtRtiExecHandshakeProcessor::lostConnection ( const MAKRti::DtString &  connName,
unsigned int  connID,
const DtInetAddrAndPort connAddr,
void *  usr 
)
static

Connection loss callback.

Referenced by DtRtiExecHandshakeProcessor().

int DtRtiExecHandshakeProcessor::lostConnection ( const MAKRti::DtString &  connName,
unsigned int  connID,
const DtInetAddrAndPort connAddr 
)
protectedvirtual
bool DtRtiExecHandshakeProcessor::processExecHandshakeDestinations ( const DtInetAddrAndPort src,
DtForwarderPort::DtAddressPortList destinations 
)
virtual

Set forwarding destination list based on source (eg.

which inlet the message was received on) and forwarder network configuration

References localNodeAddress(), and myParent.

Referenced by DtRtiExecHandshakeProcessor().

bool DtRtiExecHandshakeProcessor::processInToOutMsg ( const DtInetAddrAndPort src,
const DtRtiExecHandshakeMsg msg 
)
protectedvirtual
bool DtRtiExecHandshakeProcessor::processLanToOutMsg ( const DtInetAddrAndPort src,
const DtRtiExecHandshakeMsg msg 
)
protectedvirtual
void DtRtiExecHandshakeProcessor::sendResponseMsg ( DtRtiExecHandshakeMsg::DtHandshakeStatus  status,
DtHandle  src,
DtHandle  dest,
const MAKRti::DtString &  hostName,
bool  fullyCompliant,
const DtInetAddrAndPort addr = 0 
)
protectedvirtual

Send a handshake Response based on aggregating all Local responses and all downstream WAN responses.

References DtForwarderIntfcLan, DtForwarderIntfcOut, and myParent.

Referenced by gotMsgToLanPort(), lostConnection(), processInToOutMsg(), and processLanToOutMsg().

Member Data Documentation

unsigned long DtRtiExecHandshakeProcessor::myConnectionIdOfLocalRtiExec
protected

If valid, this represents the connID of a local exec.

Referenced by gotMsgToLanPort(), gotRtiExecDisconnect(), lostConnection(), and processInToOutMsg().

bool DtRtiExecHandshakeProcessor::myHaveConnectionIdOfLocalRtiExec
protected
DtConnIdList DtRtiExecHandshakeProcessor::myLocalRtiExecConnIds
protected

List of local rtiexec Candidates.

Referenced by gotMsgToLanPort(), gotRtiExecDisconnect(), processInToOutMsg(), and processLanToOutMsg().

DtRtiExecHandshakeFilter* DtRtiExecHandshakeProcessor::myMsgToLanFilter
protected
DtRtiExecHandshakeFilter* DtRtiExecHandshakeProcessor::myMsgToOutFilter
protected
DtBoost::shared_ptr<DtForwarderNode> DtRtiExecHandshakeProcessor::myParent
protected
DtConnIdToRequestMap DtRtiExecHandshakeProcessor::myPendingRequests
protected

Map of outstanding rtiexec Requests to Responses.

Referenced by gotMsgToLanPort(), lostConnection(), processInToOutMsg(), and processLanToOutMsg().

DtRtiExecConnectionFilter<DtRtiExecHandshakeProcessor>* DtRtiExecHandshakeProcessor::myRtiExecConnectionFilter
protected

The documentation for this class was generated from the following files:

Document ID: Generated on Fri Mar 14 19:08:55 EDT 2014 from SVN revision 137085
Copyright © 2005-2014 VT MÄK Inc. All Rights Reserved (www.mak.com)