MAK RTIspy API Documentation for HLA Evolved
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes
DtFederateCounterProcessor Class Reference

The DtFederateCounterProcessor class consists of filters for FederateCounter messages for forwarder nodes. More...

+ Collaboration diagram for DtFederateCounterProcessor:

Classes

class  PendingRequest
 Simple helper class to hold status of pending Pings. More...

Public Types

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

Public Member Functions

 DtFederateCounterProcessor (DtBoost::shared_ptr< DtForwarderNode > parent)
 Default Ctor.
virtual ~DtFederateCounterProcessor ()
 Default Dtor.
virtual bool gotMsgToOutPort (const DtInetAddrAndPort &src, const DtForwarderCounterMsg &msg)
 Got Handshake Message from the IN or LAN Port to the OUT Port.
virtual bool processCounterMsgDestinations (const DtInetAddrAndPort &src, DtForwarderPort::DtAddressPortList &destinations)
 Set forwarding destination list based on source (eg.

Static Public Member Functions

static int lostConnection (const MAKRti::DtString &connName, const MAKRti::DtString &hostName, unsigned int connID, const std::pair< DtInetAddrAndPort, DtInetAddrAndPort > &connAddr, void *usr)
 Connection loss callback.
static int reconnectBegun (const MAKRti::DtString &connName, const MAKRti::DtString &hostName, unsigned int connID, const DtInetAddrAndPort &connAddr, void *usr)

Protected Types

typedef std::map
< DtInetAddrAndPort,
PendingRequest
DtDestToRequestMap

Protected Member Functions

virtual int lostConnection (const MAKRti::DtString &connName, const MAKRti::DtString &hostName, unsigned int connID, const std::pair< DtInetAddrAndPort, DtInetAddrAndPort > &connAddr)
 Connection loss callback.
virtual int reconnectBegun (const MAKRti::DtString &connName, const MAKRti::DtString &hostName, unsigned int connID, const DtInetAddrAndPort &connAddr)
virtual void sendResponseMsg (const DtInetAddrAndPort &destination, unsigned int federateCount, const DtInetAddrAndPort *addr=0)
 Send a Count Response based on aggregating all downstream WAN responses.
virtual void requestDownstreamCount (const DtInetAddrAndPort &destination)
 Send a new downstream request indicating that the target is upstream (so all recipients should respond with their federate counts)
virtual void requestDownstreamCount (const DtInetAddrAndPort &destination, const DtRouteMap::DtAddressPortList &destinations)
virtual bool processInToOutMsg (const DtInetAddrAndPort &src, const DtForwarderCounterMsg &msg)
 Got Count Message from the IN Port to the OUT Port.
virtual bool processLanToOutMsg (const DtInetAddrAndPort &src, const DtForwarderCounterMsg &msg)
 Got Count Message from the LAN Port to the OUT Port.

Protected Attributes

DtBoost::shared_ptr
< DtForwarderNode
myParent
DtFederateCounterFiltermyMsgToOutFilter
DtDestToRequestMap myPendingRequests
 Map of outstanding Count Requests to Responses.

Detailed Description

The DtFederateCounterProcessor class consists of filters for FederateCounter messages for forwarder nodes.

The FederateCounter algorithm allows forwarder nodes or the rtiexec to obtain a count of all federates downstream from a given node (including federates directly attached to the specified node). Ie - the rtiexec could obtain a complete federate count by querying the node to which it is directly attached.

Basic Algo:

Member Typedef Documentation

typedef bool(DtFederateCounterProcessor::* DtFederateCounterProcessor::CounterMsgHandlerMemberCb)(const DtInetAddrAndPort &src, const DtForwarderCounterMsg &msg)

Pointer to member function callbacks used by the port filters.

typedef bool(DtFederateCounterProcessor::* DtFederateCounterProcessor::DestinationProcessingMemberCb)(const DtInetAddrAndPort &src, DtForwarderPort::DtAddressPortList &destinations)

Constructor & Destructor Documentation

DtFederateCounterProcessor::DtFederateCounterProcessor ( DtBoost::shared_ptr< DtForwarderNode parent)

Default Ctor.

virtual DtFederateCounterProcessor::~DtFederateCounterProcessor ( )
virtual

Default Dtor.

Member Function Documentation

virtual bool DtFederateCounterProcessor::gotMsgToOutPort ( const DtInetAddrAndPort src,
const DtForwarderCounterMsg msg 
)
virtual

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

static int DtFederateCounterProcessor::lostConnection ( const MAKRti::DtString &  connName,
const MAKRti::DtString &  hostName,
unsigned int  connID,
const std::pair< DtInetAddrAndPort, DtInetAddrAndPort > &  connAddr,
void *  usr 
)
static

Connection loss callback.

virtual int DtFederateCounterProcessor::lostConnection ( const MAKRti::DtString &  connName,
const MAKRti::DtString &  hostName,
unsigned int  connID,
const std::pair< DtInetAddrAndPort, DtInetAddrAndPort > &  connAddr 
)
protectedvirtual

Connection loss callback.

virtual bool DtFederateCounterProcessor::processCounterMsgDestinations ( 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

virtual bool DtFederateCounterProcessor::processInToOutMsg ( const DtInetAddrAndPort src,
const DtForwarderCounterMsg msg 
)
protectedvirtual

Got Count Message from the IN Port to the OUT Port.

virtual bool DtFederateCounterProcessor::processLanToOutMsg ( const DtInetAddrAndPort src,
const DtForwarderCounterMsg msg 
)
protectedvirtual

Got Count Message from the LAN Port to the OUT Port.

static int DtFederateCounterProcessor::reconnectBegun ( const MAKRti::DtString &  connName,
const MAKRti::DtString &  hostName,
unsigned int  connID,
const DtInetAddrAndPort connAddr,
void *  usr 
)
static
virtual int DtFederateCounterProcessor::reconnectBegun ( const MAKRti::DtString &  connName,
const MAKRti::DtString &  hostName,
unsigned int  connID,
const DtInetAddrAndPort connAddr 
)
protectedvirtual
virtual void DtFederateCounterProcessor::requestDownstreamCount ( const DtInetAddrAndPort destination)
protectedvirtual

Send a new downstream request indicating that the target is upstream (so all recipients should respond with their federate counts)

virtual void DtFederateCounterProcessor::requestDownstreamCount ( const DtInetAddrAndPort destination,
const DtRouteMap::DtAddressPortList destinations 
)
protectedvirtual
virtual void DtFederateCounterProcessor::sendResponseMsg ( const DtInetAddrAndPort destination,
unsigned int  federateCount,
const DtInetAddrAndPort addr = 0 
)
protectedvirtual

Send a Count Response based on aggregating all downstream WAN responses.

Member Data Documentation

DtFederateCounterFilter* DtFederateCounterProcessor::myMsgToOutFilter
protected
DtBoost::shared_ptr<DtForwarderNode> DtFederateCounterProcessor::myParent
protected
DtDestToRequestMap DtFederateCounterProcessor::myPendingRequests
protected

Map of outstanding Count Requests to Responses.


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

Document ID: Generated on Mon Jul 9 10:30:41 EDT 2018 from SVN revision 190224
Copyright © 2005-2018 VT MÄK Inc. All Rights Reserved (www.mak.com)