VR-Forces 4.0.4 Class Documentation
Public Member Functions | Protected Member Functions | Protected Attributes
DtResourceCheckInfo Class Reference

Class: DtResourceCheckInfo. More...

List of all members.

Public Member Functions

 DtResourceCheckInfo ()
 DtResourceCheckInfo (const DtResourceCheckInfo &orig)
virtual ~DtResourceCheckInfo ()
virtual DtResourceCheckInfooperator= (const DtResourceCheckInfo &)
void setResourceName (const DtString &name)
const DtStringresourceName () const
virtual void removeRequestor (const DtString &name)
const std::list< DtString > & requestors () const
virtual void setPublishCondition (int iMonitoryBy, const DtFloat64 &dMonitorPeriod, DtSimManager *manager)
 Sets up a conditional expression to be evaluated based on the iMonitoryBy setting.
virtual void addRequestor (const DtString &req)
 Adds a requestor only if the requestor does not currently exist.
virtual bool shouldPublish (double simTime, const DtString &echelonId, DtSimManager *manager) const
 Return true if this resource should be updated based on the conditional expression.
virtual void setNextPublicationPeriod (double simTime, const DtString &echelonId, DtSimManager *manager)
 Given the specified conditional expression, set the next time the expression should evaluate to true.

Protected Member Functions

virtual void createSimTimeExpression (const DtFloat64 &dMonitorPeriod)
 Creates a publish condition that is based on simulation time.
virtual void updateSimTimeExpression (double simTime, const DtString &echelonId, DtSimManager *manager)
 Simulation time -- Fire off at the current exercise time plus the buffer period.

Protected Attributes

DtString myResourceName
std::list< DtStringmyRequestors
DtFloat64 myMonitorPeriod
DtSimCondExprmyPublishCondition

Detailed Description

Class: DtResourceCheckInfo.

This class will track resources to check and expressions that determine whether or not they need to be updated on the network


Constructor & Destructor Documentation


Member Function Documentation

virtual DtResourceCheckInfo& DtResourceCheckInfo::operator= ( const DtResourceCheckInfo ) [virtual]
void DtResourceCheckInfo::setResourceName ( const DtString name) [inline]
const DtString& DtResourceCheckInfo::resourceName ( ) const [inline]
virtual void DtResourceCheckInfo::removeRequestor ( const DtString name) [virtual]
const std::list<DtString>& DtResourceCheckInfo::requestors ( ) const [inline]
virtual void DtResourceCheckInfo::setPublishCondition ( int  iMonitoryBy,
const DtFloat64 &  dMonitorPeriod,
DtSimManager manager 
) [virtual]

Sets up a conditional expression to be evaluated based on the iMonitoryBy setting.

virtual void DtResourceCheckInfo::addRequestor ( const DtString req) [virtual]

Adds a requestor only if the requestor does not currently exist.

virtual bool DtResourceCheckInfo::shouldPublish ( double  simTime,
const DtString echelonId,
DtSimManager manager 
) const [virtual]

Return true if this resource should be updated based on the conditional expression.

The simManager is supplied in case the condition needs it

virtual void DtResourceCheckInfo::setNextPublicationPeriod ( double  simTime,
const DtString echelonId,
DtSimManager manager 
) [virtual]

Given the specified conditional expression, set the next time the expression should evaluate to true.

For the current supported conditions, the following will happen:

Simulation time -- Fire off at the current exercise time plus the buffer period. If this is the first time, set a random period between 0 and the period time to fire off to prevent network flooding

virtual void DtResourceCheckInfo::createSimTimeExpression ( const DtFloat64 &  dMonitorPeriod) [protected, virtual]

Creates a publish condition that is based on simulation time.

If there is already an existing expression (sim time), it will reuse the expression but respect the faster update time. If there is not a sim time expression, it will remove the old one in favor of this

virtual void DtResourceCheckInfo::updateSimTimeExpression ( double  simTime,
const DtString echelonId,
DtSimManager manager 
) [protected, virtual]

Simulation time -- Fire off at the current exercise time plus the buffer period.

If this is the first time, set a random period between 0 and the period time to fire off to prevent network flooding


Member Data Documentation

DtFloat64 DtResourceCheckInfo::myMonitorPeriod [protected]

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

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)