VR-Vantage 2.5 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | Private Member Functions
DtVrfAggregatePublisher Class Reference

This class will wrap a VR-Link DtAggregatePublisher to allow for easier creation of a publisher that is compatible with VR-Forces. More...

Public Types

typedef
DtAggregateStateRepository *(* 
MyStateRepCreator )()

Public Member Functions

 DtVrfAggregatePublisher (const DtEntityType &type, DtExerciseConn *conn, const DtGlobalObjectDesignator &glId=DtVrfObjectIdGenerator::nullId(), const DtEntityIdentifier &entId=DtEntityIdentifier::nullId(), DtRwProperties *stateProps=0, DtRwProperties *paramProps=0)
 Create a new instance of the VRF aggregate publisher which will, in turn, create the VR-Link aggregate publisher, given a object id (DIS) or name (HLA).
 DtVrfAggregatePublisher (const DtEntityType &type, DtExerciseConn *conn, const DtGlobalObjectDesignator &glId=DtVrfObjectIdGenerator::nullId(), const DtEntityIdentifier &entId=DtEntityIdentifier::nullId(), const DtRwProperties &stateProps=DtRwProperties::emptyProperties(), const DtRwProperties &paramProps=DtRwProperties::emptyProperties())
 Create a new instance of the VRF aggregate publisher which will, in turn, create the VR-Link aggregate publisher, given a object id (DIS) or name (HLA).
virtual ~DtVrfAggregatePublisher ()
 Destructor. Also destroys publisher.
virtual void addEntity (const DtBaseEntityStateRepository *)
 Convenience routines to add/remove subordinates.
virtual void removeEntity (const DtBaseEntityStateRepository *)
virtual void addAggregate (const DtBaseEntityStateRepository *)
virtual void removeAggregate (const DtBaseEntityStateRepository *)
virtual void tick ()
 Class method taken from publisher class for aggregates at VR-Link level.
virtual DtAggPublisherDecoderdecoder ()
 Returns a pointer to the Decoder being used to decode PDUs/updates that we send back into the asSeenByRemote state rep.
virtual DtAggPublisherEncoderencoder ()
 Returns a pointer to the Encoder being used to encode current state into a PDU/update.
DtStateRepositorysr ()
 Returns the state repository.
const DtStringname () const
 Returns the name of the object.
virtual const DtObjectId & id () const
 Get the aggregate's identifier.
virtual const DtObjectId & localId () const
 Get the aggregate's localId - same as id for DIS.
virtual const
DtGlobalObjectDesignator & 
globalId () const
 Get the global object designator - same as id for DIS.
virtual void forceUpdate ()
 Force a state update to be sent during the next call to tick, even if nothing would normally cause a send.
virtual DtAggregatePublisher * aggregatePublisher ()
 Returns a pointer to myPublisher (the VR-Link DtAggregatePublisher)
virtual void setSendVrfObjectDataRecord (bool shouldSend)
 Sets whether a separate VrfObjectData record should be sent to convey additional VRF object information.
virtual void setExtendedData (const DtString &key, const DtString &value)
virtual void clearExtendedData ()
virtual void removeExtendedData (const DtString &key)
virtual DtString extendedData (const DtString &key) const
virtual
DtExtAggregateStateRepository
aggregateProcessStateRep ()
virtual
DtExtAggregateStateRepository
aggregateStateRep ()
virtual
DtExtAggregateStateRepository
agsr ()

Static Public Member Functions

static void setInitializer (DtExtendedAttributesInitializerPtr init)
 Sets the extended attributes initializer used by all publishers of this type.
static
DtExtendedAttributesInitializerPtr 
initializer ()
 Returns the extended attributes initializer used by all publishers of this type.
static void setObjectClassChooser (DtObjectClassChooserPtr chooser)
 Sets the object class chooser used by all publishers of this type.
static DtObjectClassChooserPtr objectClassChooser ()
 Returns the object class chooser used by all publishers of this type.

Protected Member Functions

 DtVrfAggregatePublisher ()
 Alternate constructor that performs no initialization.
void initialize (const DtEntityType &type, DtExerciseConn *conn, const DtGlobalObjectDesignator &glId, const DtEntityIdentifier &entId)
 Called by the constructor to initialize the publisher.

Protected Attributes

DtAggregatePublisher * myPublisher
makVrfVrlinkExtToolkit::DtExtendedAttributesObjectPublishermyExtAttrPublisher

Static Protected Attributes

static DtObjectClassChooserPtr theObjectClassChooser
static
DtExtendedAttributesInitializerPtr 
theInitializer

Private Member Functions

 DtVrfAggregatePublisher (const DtVrfAggregatePublisher &)
 Unimplemented.
DtVrfAggregatePublisheroperator= (const DtVrfAggregatePublisher &)
 Unimplemented.

Detailed Description

This class will wrap a VR-Link DtAggregatePublisher to allow for easier creation of a publisher that is compatible with VR-Forces.

If you want to create and publish aggregate objects that can be used by VR-Forces, you can use a publisher of this class to facilitate in that creation

Member Typedef Documentation

typedef DtAggregateStateRepository*(* DtVrfAggregatePublisher::MyStateRepCreator)()

Constructor & Destructor Documentation

DtVrfAggregatePublisher::DtVrfAggregatePublisher ( const DtEntityType &  type,
DtExerciseConn *  conn,
const DtGlobalObjectDesignator &  glId = DtVrfObjectIdGenerator::nullId(),
const DtEntityIdentifier &  entId = DtEntityIdentifier::nullId(),
DtRwProperties *  stateProps = 0,
DtRwProperties *  paramProps = 0 
)

Create a new instance of the VRF aggregate publisher which will, in turn, create the VR-Link aggregate publisher, given a object id (DIS) or name (HLA).

This class will use the default factory as supplied in the DtVrfObjectIdGenerator class.

The state repository will initially be set to the DtExtAggregateStateRepository class. You can change it in the global DtVrfAggregatePublisher class before calling this creator.

If supplied, initializes the state repository to publish extended attributes from the supplied state properties.

DtVrfAggregatePublisher::DtVrfAggregatePublisher ( const DtEntityType &  type,
DtExerciseConn *  conn,
const DtGlobalObjectDesignator &  glId = DtVrfObjectIdGenerator::nullId(),
const DtEntityIdentifier &  entId = DtEntityIdentifier::nullId(),
const DtRwProperties &  stateProps = DtRwProperties::emptyProperties(),
const DtRwProperties &  paramProps = DtRwProperties::emptyProperties() 
)

Create a new instance of the VRF aggregate publisher which will, in turn, create the VR-Link aggregate publisher, given a object id (DIS) or name (HLA).

This class will use the default factory as supplied in the DtVrfObjectIdGenerator class.

The state repository will initially be set to the DtExtAggregateStateRepository class. You can change it in the global DtVrfAggregatePublisher class before calling this creator.

If supplied, initializes the state repository with the provided state properties.

virtual DtVrfAggregatePublisher::~DtVrfAggregatePublisher ( )
virtual

Destructor. Also destroys publisher.

DtVrfAggregatePublisher::DtVrfAggregatePublisher ( )
protected

Alternate constructor that performs no initialization.

Can be used in subclasses to override how initialization is performed. If this constructor is used, the initialize function (or a equivalent replacement) must be called before this class will publish anything.

DtVrfAggregatePublisher::DtVrfAggregatePublisher ( const DtVrfAggregatePublisher )
private

Unimplemented.

Member Function Documentation

virtual void DtVrfAggregatePublisher::addEntity ( const DtBaseEntityStateRepository *  )
virtual

Convenience routines to add/remove subordinates.

Note that this will also effect the subordinate order that is used by VRF. This is a pass-through to the state repository.

virtual void DtVrfAggregatePublisher::removeEntity ( const DtBaseEntityStateRepository *  )
virtual
virtual void DtVrfAggregatePublisher::addAggregate ( const DtBaseEntityStateRepository *  )
virtual
virtual void DtVrfAggregatePublisher::removeAggregate ( const DtBaseEntityStateRepository *  )
virtual
virtual void DtVrfAggregatePublisher::setExtendedData ( const DtString key,
const DtString value 
)
virtual

Extended record data is a key/value pair. The value and key is always a string representation and is up to the developer to determine the format of the value. The values are set through the publisher.

virtual void DtVrfAggregatePublisher::clearExtendedData ( )
virtual

Extended record data is a key/value pair. The value and key is always a string representation and is up to the developer to determine the format of the value. The values are set through the publisher.

virtual void DtVrfAggregatePublisher::removeExtendedData ( const DtString key)
virtual

Extended record data is a key/value pair. The value and key is always a string representation and is up to the developer to determine the format of the value. The values are set through the publisher.

virtual DtString DtVrfAggregatePublisher::extendedData ( const DtString key) const
virtual

Extended record data is a key/value pair. The value and key is always a string representation and is up to the developer to determine the format of the value. The values are set through the publisher.

virtual void DtVrfAggregatePublisher::tick ( )
virtual

Class method taken from publisher class for aggregates at VR-Link level.

This will simply call down to the publisher's tick method. This function should be called once per frame for each aggregate object. It determines if any data needs to be sent to the other exercise participants, and sends that data.

virtual DtExtAggregateStateRepository* DtVrfAggregatePublisher::aggregateProcessStateRep ( )
virtual

Returns a pointer to the DtExtAggregateStateRepository - through which you can set or inspect current state information.

virtual DtExtAggregateStateRepository* DtVrfAggregatePublisher::aggregateStateRep ( )
virtual

Returns a pointer to the DtExtAggregateStateRepository - through which you can set or inspect current state information.

virtual DtExtAggregateStateRepository* DtVrfAggregatePublisher::agsr ( )
virtual

Returns a pointer to the DtExtAggregateStateRepository - through which you can set or inspect current state information.

virtual DtAggPublisherDecoder* DtVrfAggregatePublisher::decoder ( )
virtual

Returns a pointer to the Decoder being used to decode PDUs/updates that we send back into the asSeenByRemote state rep.

virtual DtAggPublisherEncoder* DtVrfAggregatePublisher::encoder ( )
virtual

Returns a pointer to the Encoder being used to encode current state into a PDU/update.

DtStateRepository* DtVrfAggregatePublisher::sr ( )
inline

Returns the state repository.

const DtString& DtVrfAggregatePublisher::name ( ) const
inline

Returns the name of the object.

virtual const DtObjectId& DtVrfAggregatePublisher::id ( ) const
virtual

Get the aggregate's identifier.

virtual const DtObjectId& DtVrfAggregatePublisher::localId ( ) const
virtual

Get the aggregate's localId - same as id for DIS.

virtual const DtGlobalObjectDesignator& DtVrfAggregatePublisher::globalId ( ) const
virtual

Get the global object designator - same as id for DIS.

virtual void DtVrfAggregatePublisher::forceUpdate ( )
virtual

Force a state update to be sent during the next call to tick, even if nothing would normally cause a send.

virtual DtAggregatePublisher* DtVrfAggregatePublisher::aggregatePublisher ( )
virtual

Returns a pointer to myPublisher (the VR-Link DtAggregatePublisher)

virtual void DtVrfAggregatePublisher::setSendVrfObjectDataRecord ( bool  shouldSend)
virtual

Sets whether a separate VrfObjectData record should be sent to convey additional VRF object information.

static void DtVrfAggregatePublisher::setInitializer ( DtExtendedAttributesInitializerPtr  init)
static

Sets the extended attributes initializer used by all publishers of this type.

static DtExtendedAttributesInitializerPtr DtVrfAggregatePublisher::initializer ( )
static

Returns the extended attributes initializer used by all publishers of this type.

static void DtVrfAggregatePublisher::setObjectClassChooser ( DtObjectClassChooserPtr  chooser)
static

Sets the object class chooser used by all publishers of this type.

static DtObjectClassChooserPtr DtVrfAggregatePublisher::objectClassChooser ( )
static

Returns the object class chooser used by all publishers of this type.

void DtVrfAggregatePublisher::initialize ( const DtEntityType &  type,
DtExerciseConn *  conn,
const DtGlobalObjectDesignator &  glId,
const DtEntityIdentifier &  entId 
)
protected

Called by the constructor to initialize the publisher.

DtVrfAggregatePublisher& DtVrfAggregatePublisher::operator= ( const DtVrfAggregatePublisher )
private

Unimplemented.

Member Data Documentation

DtAggregatePublisher* DtVrfAggregatePublisher::myPublisher
protected
makVrfVrlinkExtToolkit::DtExtendedAttributesObjectPublisher* DtVrfAggregatePublisher::myExtAttrPublisher
protected
DtObjectClassChooserPtr DtVrfAggregatePublisher::theObjectClassChooser
staticprotected
DtExtendedAttributesInitializerPtr DtVrfAggregatePublisher::theInitializer
staticprotected

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


Copyright © 2005-2019 VT MAK. All Rights Reserved (www.mak.com)