![]() |
VR-Link API Documentation for HLA 1.3
|
Instances of DtEntityPublisher are used for local or source simulations of entities (i.e. More...
Inheritance diagram for DtEntityPublisher:
Collaboration diagram for DtEntityPublisher:Public Types | |
| typedef DtEntityStateRepository *(* | DtStateRepCreator )() |
| Function prototype for functions that create DtEntityStateRepositories. | |
Public Member Functions | |
| DtEntityPublisher (DtEntityStateRepository *stateRepToUse, DtExerciseConn *conn, const char *name=0, const DtDDMRegionSet *regionSetToUse=0) | |
| Constructor – state rep must contain entityType. | |
| DtEntityPublisher (RTI::ObjectClassHandle h, DtExerciseConn *conn, const char *name=0, const DtDDMRegionSet *regionSetToUse=0) | |
| Constructor. | |
| DtEntityPublisher (const DtEntityType &type, DtExerciseConn *conn, const char *name=0, const DtDDMRegionSet *regionSetToUse=0) | |
| Constructor. | |
| DtEntityPublisher (const DtEntityType &type, DtExerciseConn *conn, DtDeadReckonTypes algorithm, DtForceType forceId, const DtEntityType &guise=guiseSameAsType(), const char *name=0, const DtDDMRegionSet *regionSetToUse=0) | |
| Constructor. | |
| DtEntityPublisher (DtHlaObjectWithStateRep *obj, DtExerciseConn *conn) | |
| Constructor that creates a publisher for an existing DtHlaObject. | |
| virtual | ~DtEntityPublisher () |
| destructor | |
| virtual DtEntityStateRepository * | entityStateRep () |
| Returns a pointer to the EntityStateRepository - through which you can set or inspect current state information. | |
| virtual DtEntityStateRepository * | esr () |
| Synonym for entityStateRep(). | |
| virtual void | enableDiGuyInformation () |
| Signals that this object has DI Guy information. | |
| virtual void | tick () |
| If there is a region, update it, and then call down to base tick. | |
| virtual DtOwnershipHandler * | setOwnershipHandler (DtOwnershipHandler *handler) |
| Sets the current ownership handler to handler. | |
| virtual void | divestObject () |
| Pass through to ownership manager. | |
Public Member Functions inherited from DtObjectPublisher | |
| DtObjectPublisher (DtExerciseConn *conn, DtStateRepository *stateRep, DtStateRepository *asSeenByRemote, bool okToDeleteStateRep=true, const DtDDMRegionSet *regionSet=0) | |
| Constructor. | |
| virtual | ~DtObjectPublisher () |
| Destructor. | |
| virtual void | setHlaObject (const char *className, DtHlaStateEncoder *encoder=0, DtHlaStateDecoder *decoder=0, const char *objectName=0, const DtDDMRegionSet *regionSet=0) |
| A DtObjectPublisher is not capable of communicating data through the RTI until setHlaObject is called. | |
| virtual void | setHlaObject (RTI::ObjectClassHandle hand, DtHlaStateEncoder *encoder=0, DtHlaStateDecoder *decoder=0, const char *objectName=0, const DtDDMRegionSet *regionSet=0) |
| This version takes a classHandle and optional object name, and creates the DtHlaObject for you. | |
| virtual void | setHlaObject (DtHlaObjectWithStateRep *obj, DtHlaStateEncoder *encoder=0, DtHlaStateDecoder *decoder=0) |
| This version takes an existing DtHlaObject, and uses it. | |
| virtual void | detachHlaObject () |
| Detach HLA object - bringing the DtObjectPublisher back to the state it was in before setHlaObject was called. | |
| virtual DtStateRepository * | stateRep () |
| Returns a pointer to the DtStateRepository - through which you can set or inspect current state information. | |
| virtual DtStateRepository * | sr () |
| Synonym for stateRep(). | |
| virtual DtStateRepository * | approximateRemoteStateRep () |
| Returns a pointer to the approximate remote DtStateRepository – This state repository contains the contents of the last sent message. | |
| virtual DtHlaStateDecoder * | decoder () |
| Returns a pointer to the Decoder being used to decode state messages that we send back into the asSeenByRemote SR. | |
| virtual DtHlaStateEncoder * | encoder () |
| Returns a pointer to the Encoder being used to encode current state into an outgoing message. | |
| virtual DtHlaObjectWithStateRep * | hlaObject () |
| Get the object's hlaObject. | |
| virtual DtExerciseConn * | exerciseConn () |
| Get our exercise connection. | |
| virtual const DtObjectId & | id () const |
| Get the object's local identifier. | |
| virtual const DtObjectId & | objectId () const |
| Get the object's local identifier. | |
| virtual const DtObjectId & | localId () const |
| Get the object's local identifier. | |
| virtual const DtString & | name () const |
| Get the object's name. | |
| virtual const DtGlobalObjectDesignator & | globalId () const |
| Get the HLA object's global object designator - the object name in RTI1.3.3, but the objectId in RTI1.0.3. | |
| virtual void | forceUpdate () |
| Specify a set of attributes that should be included in the ahvps the next time tick is called, even if they would not otherwise need to be sent. | |
| virtual void | forceUpdate (const RTI::AttributeHandleSet &set) |
| virtual void | parallelTick () |
| Tick (update) this object in parallel threads. | |
| virtual void | setDeleteObjInDtorFlag (bool onOff) |
| Set/Get a flag that determines whether to try to delete the HLA object that we represent, upon destruction of this DtObjectPublisher. | |
| virtual bool | deleteObjInDtorFlag () const |
| virtual const DtDDMRegionSet & | publishingRegions () const |
| virtual void | addRegion (DtDDMRegionSP regionToAdd) |
| Adds the specified region to the set of publishing regions, and calls associateRegionForUpdates on the RTI Ambassador. | |
| virtual void | removeRegion (DtDDMRegionSP regionToRemove) |
| Removes the specified region from the set of publishing regions, and calls unassociateRegionForUpdates on the RTI Ambassador. | |
| DtObjectPublisher (DtExerciseConn *conn, const char *name=0) | |
| These constructors and init functions are obsolete, but are here for backwards compatibility with pre-3.4 releases. | |
| void | init (RTI::ObjectClassHandle hand, DtStateRepository *stateRep, DtStateRepository *asSeenByRemote, DtHlaStateEncoder *encoder=0, DtHlaStateDecoder *decoder=0) |
| void | init (const char *className, DtStateRepository *stateRep, DtStateRepository *asSeenByRemote, DtHlaStateEncoder *encoder=0, DtHlaStateDecoder *decoder=0) |
Static Public Member Functions | |
| static const DtEntityType & | guiseSameAsType () |
| Returns a constant that can be passed to the constructor indicating that we should use the entity type as our guise. | |
| static DtStateRepCreator | setStateRepCreator (DtStateRepCreator creator) |
| Give us a function to be used for creating SRs. | |
| static void | setDfltRotationThreshold (double r) |
| static double | dfltRotationThreshold () |
| static void | setDfltTranslationThreshold (double t) |
| static double | dfltTranslationThreshold () |
Static Public Member Functions inherited from DtObjectPublisher | |
| static void | removeObjectCb (DtHlaObject *obj, void *pub) |
| Callback to be called when our underlying DtHlaObject goes away. | |
Protected Member Functions | |
| DtEntityPublisher (const char *name=0, const DtDDMRegionSet *regionSetToUse=0) | |
| Constructor which does not include the DtExerciseConn and does not register the HLA object. | |
| void | init () |
| not virtual, called from the constructor | |
| void | createGeographicRegion (DtExerciseConn *conn) |
| Creates the publishers region. | |
| DtEntityPublisher (const DtEntityPublisher &orig) | |
| copy constructor - Not Implemented | |
| DtEntityPublisher & | operator= (const DtEntityPublisher &orig) |
| assignment operator - Not Implemented | |
| const char * | objectClassNameFromType (const DtEntityType &type) |
| Non-virtual, since called from constructor. | |
Protected Member Functions inherited from DtObjectPublisher | |
| DtObjectPublisher (DtStateRepository *stateRep, DtStateRepository *asSeenByRemote, bool okToDeleteStateRep=true, const DtDDMRegionSet *regionSet=0) | |
| Constructor which does not include the DtExerciseConn. | |
| virtual void | setExerciseConn (DtExerciseConn *conn) |
| Allows the DtExerciseConn to be set after initial publisher creation. | |
| virtual void | processRemoveObject (DtHlaObject *obj) |
| Called by removeObjectCb to detachHlaObject when our underlying DtHlaObject goes away. | |
Protected Attributes | |
| DtDIGuyObjectPublisher * | myDiGuyObjectPub |
| DtBoost::shared_ptr < DtGeodeticRegion > | myGeodeticPublishingRegion |
Protected Attributes inherited from DtObjectPublisher | |
| DtExerciseConn * | myExConn |
| DtHlaObjectWithStateRep * | myHlaObj |
| DtStateRepository * | myStateRep |
| DtStateRepository * | myAsSeenByRemote |
| DtHlaStateEncoder * | myEncoder |
| DtHlaStateDecoder * | myDecoder |
| DtObjectId | myObjectId |
| bool | myOkToDeleteStateRepFlag |
| DtString | myName |
| bool | myDeleteObjInDtorFlag |
| DtDDMRegionSet | myPublishingRegions |
Static Protected Attributes | |
| static DtStateRepCreator | theStateRepCreator |
Instances of DtEntityPublisher are used for local or source simulations of entities (i.e.
these entities are not dependent on data being produced elsewhere on the network for their existence). These entities send data to the network.
| typedef DtEntityStateRepository*(* DtEntityPublisher::DtStateRepCreator)() |
Function prototype for functions that create DtEntityStateRepositories.
| DtEntityPublisher::DtEntityPublisher | ( | DtEntityStateRepository * | stateRepToUse, |
| DtExerciseConn * | conn, | ||
| const char * | name = 0, |
||
| const DtDDMRegionSet * | regionSetToUse = 0 |
||
| ) |
Constructor – state rep must contain entityType.
| DtEntityPublisher::DtEntityPublisher | ( | RTI::ObjectClassHandle | h, |
| DtExerciseConn * | conn, | ||
| const char * | name = 0, |
||
| const DtDDMRegionSet * | regionSetToUse = 0 |
||
| ) |
Constructor.
| DtEntityPublisher::DtEntityPublisher | ( | const DtEntityType & | type, |
| DtExerciseConn * | conn, | ||
| const char * | name = 0, |
||
| const DtDDMRegionSet * | regionSetToUse = 0 |
||
| ) |
Constructor.
| DtEntityPublisher::DtEntityPublisher | ( | const DtEntityType & | type, |
| DtExerciseConn * | conn, | ||
| DtDeadReckonTypes | algorithm, | ||
| DtForceType | forceId, | ||
| const DtEntityType & | guise = guiseSameAsType(), |
||
| const char * | name = 0, |
||
| const DtDDMRegionSet * | regionSetToUse = 0 |
||
| ) |
Constructor.
| DtEntityPublisher::DtEntityPublisher | ( | DtHlaObjectWithStateRep * | obj, |
| DtExerciseConn * | conn | ||
| ) |
Constructor that creates a publisher for an existing DtHlaObject.
(DtHlaObjectWithStateRep is derived from DtHlaObject.) Typically used in conjunction with ownership management, when you want to take ownership and begin updating some attributes of an object that you have already discovered.
|
virtual |
destructor
|
protected |
Constructor which does not include the DtExerciseConn and does not register the HLA object.
This is typically not desired, but may be useful in certain cases when a derived publisher wants to better control how the object is published.
|
protected |
copy constructor - Not Implemented
|
protected |
Creates the publishers region.
Not virtual, since it is called from the constructor.
| DtException | if the region cannot be created |
|
static |
|
static |
|
virtual |
Pass through to ownership manager.
|
virtual |
Signals that this object has DI Guy information.
Once this has been set, the state repositories will contain a DI Guy state repository that allows you to access this data.
|
inlinevirtual |
Returns a pointer to the EntityStateRepository - through which you can set or inspect current state information.
References DtObjectPublisher::myStateRep.
|
inlinevirtual |
Synonym for entityStateRep().
References DtObjectPublisher::myStateRep.
|
static |
Returns a constant that can be passed to the constructor indicating that we should use the entity type as our guise.
(g++ forces us to define this function before we define our constructors)
|
protected |
not virtual, called from the constructor
|
protected |
Non-virtual, since called from constructor.
If you don't like the default mapping between entity type and object class, just pass the object class handle you want to the constructor.
|
protected |
assignment operator - Not Implemented
|
static |
|
static |
|
virtual |
Sets the current ownership handler to handler.
A DtOwnershipHandler is an object that encapsulates callback function for a variety of ownership-management-related functions. Returns previous handler.
|
static |
Give us a function to be used for creating SRs.
|
virtual |
If there is a region, update it, and then call down to base tick.
Reimplemented from DtObjectPublisher.
|
protected |
|
protected |
|
staticprotected |