![]() |
MAK RTIspy API Documentation for HLA Evolved
|
DtTestManager runs network connectivity tests between local RTI components. More...
Collaboration diagram for DtTestManager:Classes | |
| struct | DtTrialDetails |
Public Member Functions | |
| DtTestManager (bool initiallyEnabled) | |
| Constructor. | |
| DtTestManager (DtFederateMgr *fedMgr, bool initiallyEnabled) | |
| Constructor. | |
| virtual | ~DtTestManager () |
| Destructor. | |
| DtRIDParameters * | params () |
| Access to RID. | |
| DtRIDParameters * | params () const |
| Const access to RID. | |
| DtFederateMgr * | fedMgr () |
| Access to federate manager. | |
| DtFederateMgr * | fedMgr () const |
| Const access to federate manager. | |
| RTI::RTIambassador * | rtiAmb () |
| Access to the federate's RTI Ambassador. | |
| RTI::RTIambassador * | rtiAmb () const |
| Const access to the federate's RTI Ambassador. | |
| virtual DtConnectionMgr * | connectMgr () |
| Access to the connection manager. | |
| virtual DtConnectionMgr * | connectMgr () const |
| Const access to the connection manager. | |
| virtual MAKRti::DtTime | time () const |
| return the current time. | |
| virtual void | postJoinInit () |
| Perform initializations that will allow tests to be run (e.g., publish and subscribe to test interaction) | |
| virtual void | resign () |
| Perform clean up from test instrumentation. | |
| virtual void | tick (unsigned long tickCount) |
| Process test activities. | |
| virtual float | averageTickPeriod () const |
| Average period between ticks. | |
| virtual void | enableNetworkTesting () |
| Enable network testing. | |
| virtual void | disableNetworkTesting () |
| Disable network testing. | |
| virtual bool | networkTestingEnabled () const |
| Is network testing enabled? | |
| void | processResign (const DtResignMsg &msg) |
| Process resign msg to maintain list of known federates. | |
| virtual bool | receiveInteraction (DtInteractionClassHandle classHandle, const DtPhvps ¶ms) |
| called by testMgr's installed fedAmbWrapper. | |
| virtual bool | testMgrCurrentlySending () const |
| returns whether the test Manager is in a sending state. | |
| virtual bool | queueMsgForSend (DtRtiMsg &msg) const |
| Add testID time stamp to message if necessary. | |
| virtual void | setTestMgrCurrentlySending (bool isSending, unsigned int testID=0) |
| Mark the test mgr as sending / not sending Also sets / clears the last sent testID. | |
| virtual bool | addSendTimeStampMetaDataIfNecessary (DtRtiMsg &msg) |
| If necessary add testing metadata to the message and to the testMgr, return whether timestamp was added. | |
| virtual bool | addReceiveTimeStampIfNecessary (DtRtiMsg &msg) |
| If necessary record receive Timestamp. | |
| virtual bool | addAsyncQueueMsgOnRecieve (DtRtiMsg &msg) |
| When the message is queued on Receive. | |
| virtual bool | isTestInteractionClassHandle (DtInteractionClassHandle classHandle) |
| Return boolean: Is the given interaction handle a test interaction? | |
| virtual void | sendStatusMessages () const |
| Update the status.... | |
Protected Types | |
| enum | DtInitiatorByType_e { DtInitiatedByExec, DtInitiatedByAssistant } |
| typedef enum DtTestManager::DtInitiatorByType_e | DtInitiatorByType |
| typedef std::multimap < DtMetadataType, MAKRti::DtTime > | DtTimeStampMap |
| typedef std::map< unsigned int, DtTimeStampMap > | DtTestToTimeStampMap |
Protected Member Functions | |
| virtual void | processSub (const DtSubInterMsg &msg) |
| Process subscribe msg to maintain a list of known federates. | |
| virtual void | processUnsub (const DtUnsubInterMsg &msg) |
| Process unsubscribe msg to maintain a list of known federates. | |
| virtual void | processChangeLatencyTestStatus (const DtAssistantChangeLatencyTestModeMsg &testMsg) |
| Processes latency test status change messages. | |
| virtual void | processChangeLatencyTestStatus (const DtChangeLatencyTestModeMsg &testMsg) |
| virtual void | changeLatencyTestRequestByType (bool initiateTest, bool continuousCommand, bool stopContinuous, bool observing, DtInitiatorByType type, MAKRti::DtTime period, unsigned int numInteractions, unsigned int payloadSize) |
| Change status according to parameters / initiator. | |
| virtual void | initiateLatencyTest () |
| if there are queued requests and the most recent trial has finished run a test. | |
| virtual void | processLatencyTest () |
| Process an active latency test. | |
| virtual bool | getTestIDFromMetaData (DtRtiMsg &msg, unsigned int &testID) const |
| virtual void | addKnownFederate (DtFederateHandle subscribedFed) |
| Add the federate to the list of known subscribed federates so we know who to send test interactions to. | |
| virtual void | removeKnownFederate (DtFederateHandle unsubscribedFed) |
| Remove the federate from the list of known federates so we don't sent to it anymore. | |
| virtual bool | atLeastOneKnownFederate () const |
| Do we know of at least one federate we can initiate a test with. | |
| virtual bool | isKnownFederateHandle (DtFederateHandle handle) const |
| Is the input federate Handle known to us? | |
| virtual void | addSendInteractionTimeStamp (unsigned int testID) |
| called by either test initiator or test recipient. | |
| virtual void | addNetSendTimeStamp (unsigned int testID, DtRtiMsg &msg) |
| called by either test initiator or test recipient. | |
| virtual void | addNetReceiveTimeStamp (unsigned int testID, const DtRtiMsg &msg) |
| called by either test initiator or test recipient. | |
| virtual void | addReceiveInteractionTimeStamp (unsigned int testID, MAKRti::DtTime timeToUse) |
| called by either test initiator or test recipient. | |
| virtual void | removeKnowledgeOfTestId (unsigned int testID) |
| Remove knowledge of this testID. | |
| virtual void | addAsyncQueueMsgTimeStamp (unsigned int &testID, const DtRtiMsg &msg) |
| called by either test initiator or test recipient. | |
| MAKRti::DtTransportType | transportTypeForTestID (unsigned int testID) |
| look up the transport type for this testID. | |
| virtual unsigned int | lastSentTestID () const |
| called by test initiator only. | |
| virtual void | setLastSentTestID (unsigned int testID) |
| Set the Test ID of the last sent interaction. | |
| virtual bool | sendSingleLatencyInteraction (unsigned int testID, DtFederateHandle recipient, MAKRti::DtTransportType transport, unsigned int payload) |
| Send a single latency interaction. | |
| virtual bool | addMetadataIfNecessary (DtRtiMsg &msg, unsigned int &testID) const |
| Before netsend, set the msgs's metadata from the testID. | |
| virtual bool | shouldAddMetadataToMessage (DtRtiMsg &msg) const |
| determine if adding metadata is necessary based on msg type and current state. | |
| virtual bool | isInitiatorOfTestID (unsigned int testID) const |
| Was this testID generated by me? | |
| virtual void | calculateTickTime (unsigned long tickCount) |
| Calculate Average TickTime. | |
| virtual bool | sendInteraction (unsigned int testID, DtInteractionClassHandle handle, const DtPhvps ¶ms, unsigned int payloadSize) |
| called by testManager when either a new test interaction is being sent or when a test Interaction is being sent as a response to a received test Interaction. | |
Static Protected Member Functions | |
| static void | processSub (const DtSubInterMsg &msg, void *usr) |
| Callback to install for processing subscription messages. | |
| static void | processUnsub (const DtUnsubInterMsg &msg, void *usr) |
| Callback to install for processing unsubscribe messages. | |
| static void | queueLatencyTestRequest (const DtAssistantChangeLatencyTestModeMsg &testMsg, void *usr) |
| Callback to install for processing initiate latency test messages. | |
| static void | processChangeLatencyTestStatus (const DtAssistantChangeLatencyTestModeMsg &testMsg, void *usr) |
| Processes latency test status change messages. | |
| static void | processChangeLatencyTestStatus (const DtChangeLatencyTestModeMsg &testMsg, void *usr) |
Protected Attributes | |
| DtFederateMgr * | myFedMgr |
| The federate manager. | |
| DtInitiatorLatencyTest * | myInitiatorTest |
| Handles initiating tests with other federates. | |
| DtRecipientLatencyTest * | myRecipientTest |
| Handles receiving tests from other federates. | |
| DtLatencyTestInteraction * | myLatencyInteraction |
| The latency test interaction. | |
| MAKRti::DtClock | myClock |
| Keep track of time. | |
| bool | myRunningContinuous |
| Are we currently running a continuous test? | |
| DtTrialDetails | myContinuousDetails |
| If so what are the details of the continuous test? | |
| std::set< DtInitiatorByType > | myObservers |
| list of observers. | |
| DtTestToTimeStampMap | myCompletedAveragedInitiatedTests |
| Storage of my completed initiated tests. | |
| bool | mySendingInteraction |
| Set when testMgr sends a message, is cleared by accessor when connectMgr checks whether the last message was a testMgr msg. | |
| unsigned int | myTestIDOfLastSentInteraction |
| The testID of the currently running initiated test. | |
| unsigned int | myCurrentTrialID |
| What is the current trial number. | |
| unsigned int | myInitiatedTrialID |
| What trials am I waiting to complete? | |
| DtFederateHandle | myInitiatedFedHandle |
| DtTestMgrFedAmbWrapper * | myTestFedAmbWrapper |
| Catches calls to ReceiveInteraction to prevent testInteractions from being delivered to the user. | |
| std::list< DtTrialDetails > | myTrialsToInitiate |
| List of trials to initiate. | |
| std::set< DtFederateHandle > | myListOfKnownFederates |
| Our list of known federates (not including self). | |
| float | myInitialTickTime |
| the earliest tick time we're using for avgTickPeriod. | |
| unsigned long | myInitialTickCount |
| the earliest tick count we're using for avgTickPeriod. | |
| float | mySecondTickTime |
| the second tick time we're using for avgTickPeriod. | |
| unsigned long | mySecondTickCount |
| the second tick count we're using for avgTickPeriod. | |
| float | myAverageTickPeriod |
| The average period between ticks. | |
| bool | myEnabled |
| Is network testing enabled? | |
| unsigned | myNumInitiatedTests |
| The number of tests this federate has initiated. | |
| unsigned | myNumTestReportsGenerated |
| The number of test reports this federate has generated. | |
| DtMutex | myInitiatorMutex |
| lock for the initiator test | |
| DtMutex | myRecipientMutex |
Private Member Functions | |
| DtTestManager (DtTestManager const &orig) | |
| Copy Constructor - not allowed. | |
| DtTestManager & | operator= (DtTestManager const &orig) |
| Assignment operator - not allowed. | |
DtTestManager runs network connectivity tests between local RTI components.
|
protected |
|
protected |
|
protected |
|
protected |
| DtTestManager::DtTestManager | ( | bool | initiallyEnabled | ) |
Constructor.
References myInitialTickTime, mySecondTickTime, and time().
| DtTestManager::DtTestManager | ( | DtFederateMgr * | fedMgr, |
| bool | initiallyEnabled | ||
| ) |
Constructor.
References disableNetworkTesting(), enableNetworkTesting(), myEnabled, myInitialTickTime, mySecondTickTime, and time().
|
virtual |
Destructor.
References connectMgr(), fedMgr(), myInitiatorTest, myLatencyInteraction, myRecipientTest, processChangeLatencyTestStatus(), processSub(), processUnsub(), DtSubInterMsg::removeCallback(), DtUnsubInterMsg::removeCallback(), DtChangeLatencyTestModeMsg::removeCallback(), and DtAssistantChangeLatencyTestModeMsg::removeCallback().
|
private |
Copy Constructor - not allowed.
|
virtual |
When the message is queued on Receive.
Synchronous mode: does not occur. Asynchronous mode: does not occur. AsyncProcessMessage mode: after the message's callbacks are converted into a fedAmbQueue Message and its processing is performed
References addAsyncQueueMsgTimeStamp(), and getTestIDFromMetaData().
Referenced by DtAsyncConnectionMgr::processMsgQueueCallbacks().
|
protectedvirtual |
called by either test initiator or test recipient.
If not test is currently being performed this is a nop Test manager will record the current time and associate it with the appropriate testID extracted from the message's metadata. The testID is returned.
References DtRecipientLatencyTest::addAsyncQueueMsgTimeStamp(), DtInitiatorLatencyTest::addAsyncQueueMsgTimeStamp(), isInitiatorOfTestID(), myInitiatorMutex, myInitiatorTest, myRecipientMutex, and myRecipientTest.
Referenced by addAsyncQueueMsgOnRecieve().
|
protectedvirtual |
Add the federate to the list of known subscribed federates so we know who to send test interactions to.
References myListOfKnownFederates, and sendStatusMessages().
Referenced by processSub().
|
protectedvirtual |
Before netsend, set the msgs's metadata from the testID.
return whether it was necessary to add metadata.
References DtRtiMtdTestId::get(), lastSentTestID(), DtRtiMtdTestId::set(), and shouldAddMetadataToMessage().
Referenced by addSendTimeStampMetaDataIfNecessary(), and queueMsgForSend().
|
protectedvirtual |
called by either test initiator or test recipient.
If no test is currently being performed this is a nop. Test manager will record the current time and associate it with the appropriate testID extracted from the message's metadata. That testID is returned in the first argument.
References DtRecipientLatencyTest::addNetReceiveTimeStamp(), DtInitiatorLatencyTest::addNetReceiveTimeStamp(), isInitiatorOfTestID(), myInitiatorMutex, myInitiatorTest, myRecipientMutex, and myRecipientTest.
Referenced by addReceiveTimeStampIfNecessary().
|
protectedvirtual |
called by either test initiator or test recipient.
If no test is currently being performed this is a nop. Test manager will remove all stored timestamps of testID Test manager will set the testMsg flag in the InteractionMsg. and insert them as metadata to the msg.
References DtRecipientLatencyTest::addNetSendTimeStamp(), DtInitiatorLatencyTest::addNetSendTimeStamp(), isInitiatorOfTestID(), myInitiatorMutex, myInitiatorTest, myRecipientMutex, and myRecipientTest.
Referenced by addSendTimeStampMetaDataIfNecessary().
|
protectedvirtual |
called by either test initiator or test recipient.
If no test is currently being performed this is a nop. Test Manager will record the current time and associate it with the testID
References DtRecipientLatencyTest::addReceiveInteractionTimeStamp(), DtInitiatorLatencyTest::addReceiveInteractionTimeStamp(), isInitiatorOfTestID(), myInitiatorMutex, myInitiatorTest, myRecipientMutex, and myRecipientTest.
Referenced by receiveInteraction().
|
virtual |
If necessary record receive Timestamp.
References addNetReceiveTimeStamp(), and getTestIDFromMetaData().
Referenced by DtConnectionMgr::getMessage(), DtNetStatsAsyncConnMgr::processConnection(), DtConnectionMgr::processConnection(), and DtAsyncConnectionMgr::receivePacket().
|
protectedvirtual |
called by either test initiator or test recipient.
If no test is currently being performed this is a nop. Test manager will record the current time and associate it with the input test ID.
References DtRecipientLatencyTest::addSendInteractionTimeStamp(), DtInitiatorLatencyTest::addSendInteractionTimeStamp(), isInitiatorOfTestID(), myInitiatorMutex, myInitiatorTest, myRecipientMutex, and myRecipientTest.
Referenced by sendInteraction().
|
virtual |
If necessary add testing metadata to the message and to the testMgr, return whether timestamp was added.
References addMetadataIfNecessary(), addNetSendTimeStamp(), and setTestMgrCurrentlySending().
Referenced by DtConnectionMgr::send(), and DtAsyncConnectionMgr::sendPackets().
|
protectedvirtual |
Do we know of at least one federate we can initiate a test with.
References myListOfKnownFederates.
Referenced by initiateLatencyTest(), and sendStatusMessages().
|
virtual |
Average period between ticks.
References myAverageTickPeriod.
Referenced by DtRecipientLatencyTest::addNetSendTimeStamp(), and DtInitiatorLatencyTest::averageReports().
|
protectedvirtual |
Calculate Average TickTime.
References myAverageTickPeriod, myInitialTickCount, myInitialTickTime, mySecondTickCount, mySecondTickTime, and time().
Referenced by tick().
|
protectedvirtual |
Change status according to parameters / initiator.
References DtTestManager::DtTrialDetails::continuous, DtTestManager::DtTrialDetails::federateHandle, DtTestManager::DtTrialDetails::initiatorType, myContinuousDetails, myCurrentTrialID, myEnabled, myListOfKnownFederates, myNumInitiatedTests, myObservers, myRunningContinuous, myTrialsToInitiate, DtTestManager::DtTrialDetails::numInteractions, DtTestManager::DtTrialDetails::payLoadSize, DtTestManager::DtTrialDetails::period, sendStatusMessages(), and DtTestManager::DtTrialDetails::trialID.
Referenced by processChangeLatencyTestStatus().
|
virtual |
Access to the connection manager.
References DtFederateMgr::connectMgr(), and fedMgr().
Referenced by DtInitiatorLatencyTest::currTestId(), isInitiatorOfTestID(), postJoinInit(), processResign(), processSub(), processUnsub(), resign(), DtInitiatorLatencyTest::takeCompletedTestReport(), and ~DtTestManager().
|
virtual |
Const access to the connection manager.
References DtFederateMgr::connectMgr(), and fedMgr().
|
virtual |
Disable network testing.
References myEnabled, myRunningContinuous, myTrialsToInitiate, and sendStatusMessages().
Referenced by DtTestManager(), and DtFederateMgr::processEnableDisableNetworkTesting().
|
virtual |
Enable network testing.
References myEnabled, and sendStatusMessages().
Referenced by DtTestManager(), and DtFederateMgr::processEnableDisableNetworkTesting().
| DtFederateMgr * DtTestManager::fedMgr | ( | ) |
Access to federate manager.
References myFedMgr.
Referenced by DtRecipientLatencyTest::addNetSendTimeStamp(), connectMgr(), params(), postJoinInit(), receiveInteraction(), resign(), rtiAmb(), sendInteraction(), sendSingleLatencyInteraction(), DtInitiatorLatencyTest::takeCompletedTestReport(), and ~DtTestManager().
| DtFederateMgr * DtTestManager::fedMgr | ( | ) | const |
Const access to federate manager.
References myFedMgr.
|
protectedvirtual |
References DtRtiMtdTestId::get(), DtRtiMsg::isInteractionMsgType(), DtNetMsgHeader::metadataInMessage(), and DtRtiMsg::netHeader().
Referenced by addAsyncQueueMsgOnRecieve(), and addReceiveTimeStampIfNecessary().
|
protectedvirtual |
if there are queued requests and the most recent trial has finished run a test.
References atLeastOneKnownFederate(), DtInitiatorLatencyTest::canInitiateTest(), DtTestManager::DtTrialDetails::federateHandle, DtInitiatorLatencyTest::initiateLatencyTest(), myInitiatedFedHandle, myInitiatedTrialID, myInitiatorMutex, myInitiatorTest, myTrialsToInitiate, DtTestManager::DtTrialDetails::numInteractions, DtTestManager::DtTrialDetails::payLoadSize, DtTestManager::DtTrialDetails::period, and DtTestManager::DtTrialDetails::trialID.
Referenced by tick().
|
protectedvirtual |
Was this testID generated by me?
References connectMgr(), DtRIDParameters::maxObjectsPerFederate(), and params().
Referenced by addAsyncQueueMsgTimeStamp(), addNetReceiveTimeStamp(), addNetSendTimeStamp(), addReceiveInteractionTimeStamp(), addSendInteractionTimeStamp(), receiveInteraction(), and removeKnowledgeOfTestId().
|
protectedvirtual |
Is the input federate Handle known to us?
References myListOfKnownFederates.
|
virtual |
Return boolean: Is the given interaction handle a test interaction?
References DtTestInteraction::classHandle(), and myLatencyInteraction.
Referenced by processSub(), processUnsub(), and receiveInteraction().
|
protectedvirtual |
called by test initiator only.
TestManager does not support more than one concurrent test to be initiated. Returns whether test can be successfully initiated. returns the testID of the last interaction sendInteraction was called for.
References myTestIDOfLastSentInteraction.
Referenced by addMetadataIfNecessary().
|
virtual |
|
private |
Assignment operator - not allowed.
| DtRIDParameters * DtTestManager::params | ( | ) |
Access to RID.
References fedMgr(), and DtFederateMgr::params().
Referenced by DtRecipientLatencyTest::addNetSendTimeStamp(), DtInitiatorLatencyTest::consumeTestId(), DtInitiatorLatencyTest::currTestId(), DtInitiatorLatencyTest::getCompletedReportByTestID(), DtInitiatorLatencyTest::initiateLatencyTest(), isInitiatorOfTestID(), and DtInitiatorLatencyTest::takeCompletedTestReport().
| DtRIDParameters * DtTestManager::params | ( | ) | const |
Const access to RID.
References fedMgr(), and DtFederateMgr::params().
|
virtual |
Perform initializations that will allow tests to be run (e.g., publish and subscribe to test interaction)
References DtSubInterMsg::addCallback(), DtUnsubInterMsg::addCallback(), DtChangeLatencyTestModeMsg::addCallback(), DtAssistantChangeLatencyTestModeMsg::addCallback(), DtConnectionMgr::addFedAmbWrapper(), addTestToFom(), DtTestInteraction::classHandle(), connectMgr(), fedMgr(), DtFederateMgr::interMgr(), myFedMgr, myInitiatorTest, myLatencyInteraction, myRecipientTest, myTestFedAmbWrapper, processChangeLatencyTestStatus(), processSub(), processUnsub(), DtInteractionMgr::publish(), DtInteractionMgr::subscribe(), and theTestMgrFedAmbWrapperName.
|
protectedvirtual |
Processes latency test status change messages.
This includes informing the LRC that there is an observer of the tests, that there is no longer an observer, initiating a test, stopping a test, etc.
References changeLatencyTestRequestByType(), DtAssistantChangeLatencyTestModeMsg::continuousUpdate(), DtInitiatedByAssistant, DtAssistantChangeLatencyTestModeMsg::interactionPeriod(), DtAssistantChangeLatencyTestModeMsg::numInteractions(), DtAssistantChangeLatencyTestModeMsg::observingResults(), DtAssistantChangeLatencyTestModeMsg::payloadBytes(), DtAssistantChangeLatencyTestModeMsg::runTest(), and DtAssistantChangeLatencyTestModeMsg::shouldHaltContinuous().
Referenced by postJoinInit(), processChangeLatencyTestStatus(), and ~DtTestManager().
|
protectedvirtual |
References changeLatencyTestRequestByType(), DtChangeLatencyTestModeMsg::continuousUpdate(), DtInitiatedByExec, DtFederateMgr::federateHandle(), DtChangeLatencyTestModeMsg::initiator(), DtChangeLatencyTestModeMsg::interactionPeriod(), myFedMgr, DtChangeLatencyTestModeMsg::numInteractions(), DtChangeLatencyTestModeMsg::observingResults(), DtChangeLatencyTestModeMsg::payloadBytes(), DtChangeLatencyTestModeMsg::runTest(), and DtChangeLatencyTestModeMsg::shouldHaltContinuous().
|
staticprotected |
Processes latency test status change messages.
This includes informing the LRC that there is an observer of the tests, that there is no longer an observer, initiating a test, stopping a test, etc.
References processChangeLatencyTestStatus().
|
staticprotected |
References processChangeLatencyTestStatus().
|
protectedvirtual |
Process an active latency test.
References DtFederateMgr::assistantClient(), DtTestManager::DtTrialDetails::continuous, DtInitiatedByAssistant, DtInitiatedByExec, DtTestManager::DtTrialDetails::federateHandle, myContinuousDetails, myCurrentTrialID, myFedMgr, myInitiatedFedHandle, myInitiatedTrialID, myInitiatorMutex, myInitiatorTest, myNumTestReportsGenerated, myObservers, myRunningContinuous, myTrialsToInitiate, networkTestingEnabled(), DtFederateMgr::reportLatencyTestResults(), DtRtiAssistantClient::sendLatencyTestMsg(), sendStatusMessages(), DtInitiatorLatencyTest::takeCompletedTestReport(), DtTestManager::DtTrialDetails::trialID, and DtInitiatorLatencyTest::trialIsFinished().
Referenced by tick().
| void DtTestManager::processResign | ( | const DtResignMsg & | msg | ) |
Process resign msg to maintain list of known federates.
References connectMgr(), DtRtiMsg::federateHandle(), DtConnectionMgr::fedHandle(), and removeKnownFederate().
Referenced by DtFederateMgr::processResign().
|
protectedvirtual |
Process subscribe msg to maintain a list of known federates.
References addKnownFederate(), connectMgr(), DtTestManager::DtTrialDetails::federateHandle, DtRtiMsg::federateHandle(), DtConnectionMgr::fedHandle(), DtSubInterMsg::handle(), isTestInteractionClassHandle(), myContinuousDetails, myCurrentTrialID, myRunningContinuous, myTrialsToInitiate, and DtTestManager::DtTrialDetails::trialID.
Referenced by postJoinInit(), processSub(), resign(), and ~DtTestManager().
|
staticprotected |
Callback to install for processing subscription messages.
References processSub().
|
protectedvirtual |
Process unsubscribe msg to maintain a list of known federates.
References connectMgr(), DtRtiMsg::federateHandle(), DtConnectionMgr::fedHandle(), DtUnsubInterMsg::handle(), isTestInteractionClassHandle(), and removeKnownFederate().
Referenced by postJoinInit(), processUnsub(), resign(), and ~DtTestManager().
|
staticprotected |
Callback to install for processing unsubscribe messages.
References processUnsub().
|
staticprotected |
Callback to install for processing initiate latency test messages.
|
virtual |
Add testID time stamp to message if necessary.
References addMetadataIfNecessary().
Referenced by DtAsyncConnectionMgr::queueMsg().
|
virtual |
called by testMgr's installed fedAmbWrapper.
Returns true if Interaction was a networkTest Interaction and has been processed and should be dropped. Else false.
References addReceiveInteractionTimeStamp(), DtFederateMgr::federateHandle(), fedMgr(), isInitiatorOfTestID(), isTestInteractionClassHandle(), myFedMgr, myInitiatorMutex, myInitiatorTest, myLatencyInteraction, myRecipientMutex, myRecipientTest, DtLatencyTestInteraction::parameters(), DtTestInteraction::payloadSize(), removeKnowledgeOfTestId(), sendInteraction(), DtLatencyTestInteraction::setFromParameters(), DtTestInteraction::setTestId(), DtTestInteraction::setTransportType(), DtTestInteraction::targetFederate(), DtTestInteraction::testId(), DtInitiatorLatencyTest::testIsFinished(), time(), and DtLatencyTest::transportTypeForTestID().
|
protectedvirtual |
Remove knowledge of this testID.
Typically called when we're stored time stamps for a received message and then later determined it was not addressed to us.
References isInitiatorOfTestID(), myInitiatorMutex, myInitiatorTest, myRecipientMutex, myRecipientTest, and DtLatencyTest::removeKnowledgeOfTestId().
Referenced by receiveInteraction().
|
protectedvirtual |
Remove the federate from the list of known federates so we don't sent to it anymore.
References myListOfKnownFederates, myTrialsToInitiate, and sendStatusMessages().
Referenced by processResign(), and processUnsub().
|
virtual |
Perform clean up from test instrumentation.
References DtTestInteraction::classHandle(), connectMgr(), fedMgr(), DtFederateMgr::interMgr(), myLatencyInteraction, myTestFedAmbWrapper, processSub(), processUnsub(), DtSubInterMsg::removeCallback(), DtUnsubInterMsg::removeCallback(), DtConnectionMgr::removeFedAmbWrapper(), theTestMgrFedAmbWrapperName, DtInteractionMgr::unpublish(), and DtInteractionMgr::unsubscribe().
| RTI::RTIambassador * DtTestManager::rtiAmb | ( | ) |
Access to the federate's RTI Ambassador.
References fedMgr(), and DtFederateMgr::rtiAmb().
| RTI::RTIambassador * DtTestManager::rtiAmb | ( | ) | const |
Const access to the federate's RTI Ambassador.
References fedMgr(), and DtFederateMgr::rtiAmb().
|
protectedvirtual |
called by testManager when either a new test interaction is being sent or when a test Interaction is being sent as a response to a received test Interaction.
Returns true if Interaction was a networkTest Interaction and has been processed and should be dropped. Else false.
References addSendInteractionTimeStamp(), DtTestInteraction::classHandle(), DtDefaultRegionSetHandle, fedMgr(), DtFederateMgr::interMgr(), myLatencyInteraction, DtInteractionMgr::send(), setTestMgrCurrentlySending(), and DtInteractionMgr::setTransport().
Referenced by receiveInteraction(), and sendSingleLatencyInteraction().
|
protectedvirtual |
Send a single latency interaction.
References DtTestInteraction::classHandle(), fedMgr(), myLatencyInteraction, DtLatencyTestInteraction::parameters(), DtTestInteraction::payloadSize(), sendInteraction(), DtTestInteraction::setPayloadSize(), DtTestInteraction::setTargetFederate(), DtTestInteraction::setTestId(), and DtTestInteraction::setTransportType().
Referenced by tick().
|
virtual |
Update the status....
References DtFederateMgr::assistantClient(), atLeastOneKnownFederate(), DtFederateMgr::federateHandle(), DtFederateMgr::fedExHandle(), myEnabled, myFedMgr, myNumInitiatedTests, myNumTestReportsGenerated, myRunningContinuous, myTrialsToInitiate, DtFederateMgr::reportLatencyTestStatus(), and DtRtiAssistantClient::sendLatencyTestStatusMsg().
Referenced by addKnownFederate(), changeLatencyTestRequestByType(), disableNetworkTesting(), enableNetworkTesting(), processLatencyTest(), and removeKnownFederate().
|
protectedvirtual |
Set the Test ID of the last sent interaction.
References myTestIDOfLastSentInteraction.
Referenced by setTestMgrCurrentlySending().
|
virtual |
Mark the test mgr as sending / not sending Also sets / clears the last sent testID.
References mySendingInteraction, and setLastSentTestID().
Referenced by addSendTimeStampMetaDataIfNecessary(), and sendInteraction().
|
protectedvirtual |
determine if adding metadata is necessary based on msg type and current state.
References DtRtiMsg::isInteractionMsgType(), and testMgrCurrentlySending().
Referenced by addMetadataIfNecessary().
|
virtual |
returns whether the test Manager is in a sending state.
References mySendingInteraction.
Referenced by shouldAddMetadataToMessage().
|
virtual |
Process test activities.
References calculateTickTime(), DtInitiatorLatencyTest::getCurrentTestInfo(), initiateLatencyTest(), myInitiatedTrialID, myInitiatorMutex, myInitiatorTest, processLatencyTest(), sendSingleLatencyInteraction(), and DtInitiatorLatencyTest::tick().
Referenced by DtFederateMgr::tick().
|
virtual |
return the current time.
References myClock.
Referenced by calculateTickTime(), DtTestManager(), DtInitiatorLatencyTest::initiateLatencyTest(), receiveInteraction(), DtInitiatorLatencyTest::tick(), and DtLatencyTest::time().
|
protected |
look up the transport type for this testID.
|
protected |
The average period between ticks.
Referenced by averageTickPeriod(), and calculateTickTime().
|
protected |
Keep track of time.
Referenced by time().
|
protected |
Storage of my completed initiated tests.
|
protected |
If so what are the details of the continuous test?
Referenced by changeLatencyTestRequestByType(), processLatencyTest(), and processSub().
|
protected |
What is the current trial number.
Referenced by changeLatencyTestRequestByType(), processLatencyTest(), and processSub().
|
protected |
Is network testing enabled?
Referenced by changeLatencyTestRequestByType(), disableNetworkTesting(), DtTestManager(), enableNetworkTesting(), networkTestingEnabled(), and sendStatusMessages().
|
protected |
The federate manager.
Referenced by fedMgr(), postJoinInit(), processChangeLatencyTestStatus(), processLatencyTest(), receiveInteraction(), and sendStatusMessages().
|
protected |
the earliest tick count we're using for avgTickPeriod.
Referenced by calculateTickTime().
|
protected |
the earliest tick time we're using for avgTickPeriod.
Referenced by calculateTickTime(), and DtTestManager().
|
protected |
Referenced by initiateLatencyTest(), and processLatencyTest().
|
protected |
What trials am I waiting to complete?
Referenced by initiateLatencyTest(), processLatencyTest(), and tick().
|
protected |
lock for the initiator test
Referenced by addAsyncQueueMsgTimeStamp(), addNetReceiveTimeStamp(), addNetSendTimeStamp(), addReceiveInteractionTimeStamp(), addSendInteractionTimeStamp(), initiateLatencyTest(), processLatencyTest(), receiveInteraction(), removeKnowledgeOfTestId(), and tick().
|
protected |
Handles initiating tests with other federates.
Referenced by addAsyncQueueMsgTimeStamp(), addNetReceiveTimeStamp(), addNetSendTimeStamp(), addReceiveInteractionTimeStamp(), addSendInteractionTimeStamp(), initiateLatencyTest(), postJoinInit(), processLatencyTest(), receiveInteraction(), removeKnowledgeOfTestId(), tick(), and ~DtTestManager().
|
protected |
The latency test interaction.
Referenced by isTestInteractionClassHandle(), postJoinInit(), receiveInteraction(), resign(), sendInteraction(), sendSingleLatencyInteraction(), and ~DtTestManager().
|
protected |
Our list of known federates (not including self).
Populated and maintained through DtTestManager::subInterMsg, and DtTestManager::UnsubInterMsg calls which only monitors the interaction class handles of known testInteractions.
Referenced by addKnownFederate(), atLeastOneKnownFederate(), changeLatencyTestRequestByType(), isKnownFederateHandle(), and removeKnownFederate().
|
protected |
The number of tests this federate has initiated.
Referenced by changeLatencyTestRequestByType(), and sendStatusMessages().
|
protected |
The number of test reports this federate has generated.
Referenced by processLatencyTest(), and sendStatusMessages().
|
protected |
list of observers.
Referenced by changeLatencyTestRequestByType(), and processLatencyTest().
|
protected |
|
protected |
Handles receiving tests from other federates.
Referenced by addAsyncQueueMsgTimeStamp(), addNetReceiveTimeStamp(), addNetSendTimeStamp(), addReceiveInteractionTimeStamp(), addSendInteractionTimeStamp(), postJoinInit(), receiveInteraction(), removeKnowledgeOfTestId(), and ~DtTestManager().
|
protected |
Are we currently running a continuous test?
Referenced by changeLatencyTestRequestByType(), disableNetworkTesting(), processLatencyTest(), processSub(), and sendStatusMessages().
|
protected |
the second tick count we're using for avgTickPeriod.
Referenced by calculateTickTime().
|
protected |
the second tick time we're using for avgTickPeriod.
Referenced by calculateTickTime(), and DtTestManager().
|
protected |
Set when testMgr sends a message, is cleared by accessor when connectMgr checks whether the last message was a testMgr msg.
Should ONLY be changed by a test Manager.
Referenced by setTestMgrCurrentlySending(), and testMgrCurrentlySending().
|
protected |
Catches calls to ReceiveInteraction to prevent testInteractions from being delivered to the user.
Referenced by postJoinInit(), and resign().
|
protected |
The testID of the currently running initiated test.
Undefined when not currently running initiated test.
Referenced by lastSentTestID(), and setLastSentTestID().
|
protected |
List of trials to initiate.
Referenced by changeLatencyTestRequestByType(), disableNetworkTesting(), initiateLatencyTest(), processLatencyTest(), processSub(), removeKnownFederate(), and sendStatusMessages().