VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions
DtSimObjectManager Class Reference

This class is the central access point for all current-frame state of all objects in the simulation in a read-only form. This includes all simulation objects for the sim engine, including locally simulated objects, and remote objects received from the network, both VRF simulated and non-VRF simulated. This gives access to the external state of all of these objects and their current-frame state in a manner that is thread-safe during the simulation frame.

Related Examples
Inheritance diagram for DtSimObjectManager:
Inheritance graph
[legend]

Public Member Functions

 DtSimObjectManager (DtSimulationServices *m)
 
virtual ~DtSimObjectManager () override
 
virtual bool hasValidSimulatedEntity () const
 
DtSimulationServices * simulationServices ()
 
virtual DtSimObjectReferenceList entitiesTracking (const DtUUID &) const
 
virtual DtSimObjectReferenceList entitiesJamming (const DtUUID &) const
 
virtual
makVrf::DtStateDataWrapper * 
createSimObject (makVrf::DtStateData *sd) const override
 
virtual
makVrf::DtStateDataWrapper * 
createSimObject (const DtUUID &uuid) const override
 
virtual
makVrf::DtStateDataWrapper * 
createSimObject (const DtEntityIdentifier &entId) const override
 
virtual void referenceAdded (makVrf::DtSimObjectReferenceTemplate< DtSimObject > ref) override
 
virtual void objectsEmbarkedOn (const DtUUID &, std::vector< DtSimObjectReference > &list) const
 
- Public Member Functions inherited from makVrf::DtSimObjectManagerTemplate< DtSimObject >
 DtSimObjectManagerTemplate (DtStateDataManager *m)
 
virtual ~DtSimObjectManagerTemplate ()
 
virtual void tick ()
 
virtual void init ()
 
virtual void advanceFrame ()
 
virtual
DtSimObjectReferenceTemplate
< DtSimObject > 
lookup (const DtUUID &) const
 
virtual
DtSimObjectReferenceTemplate
< DtSimObject > 
lookup (const DtEntityIdentifier &) const
 
virtual
DtSimObjectReferenceTemplate
< DtSimObject > 
lookup (unsigned long long) const
 
virtual DtStateData * stateDataFor (const DtUUID &) const
 
virtual DtStateData * stateDataFor (unsigned long long) const
 
virtual DtStateData * stateDataFor (const DtEntityIdentifier &) const
 
virtual DtStateData * stateDataForUniqueId (unsigned long long) const
 
SimObjects simObjects ()
 
const SimObjects & simObjects () const
 
void attachStateDataManager (DtStateDataManager *)
 
void detachStateDataManager (DtStateDataManager *)
 
virtual void clear ()
 
virtual bool has (const DtUUID &) const
 
virtual bool has (unsigned long long) const
 
CurrentFrameStates stateComponents () const
 
StateComponentAddedSignal & signalWhenStateComponentAdded ()
 
StateComponentAddedSignal & signalWhenStateComponentRemoved ()
 
virtual std::vector
< DtSimObjectReferenceTemplate
< DtSimObject > > 
objectsOfType (const DtEntityType &) const
 

Protected Member Functions

virtual void uuidChanged (unsigned long long, const DtUUID &oldUUID, const DtUUID &newUUID) override
 
- Protected Member Functions inherited from makVrf::DtSimObjectManagerTemplate< DtSimObject >
virtual void simObjectDeleted (const DtStateDataWrapper *)
 
virtual void stateDataDeleted (const DtStateData *)
 
virtual
DtSimObjectReferenceTemplate
< DtSimObject > 
getOrCreateSimObjectReference (DtStateData *, bool createOnlyIfNotPresent=false) const
 
virtual void uuidChanged (unsigned long long, const DtUUID &oldUUID, const DtUUID &newUUID)
 
virtual void objectRenamed (const DtStateDataWrapper *, const DtString &oldName, const DtString &newName)
 
virtual void simObjectAdded (DtStateData *)
 
virtual void discoveredObjectReference (const DtString &awaiting)
 
bool isDeleted (const DtUUID &) const
 
virtual void slot_uuidUpgradedTo (const DtUUID &oldUUID, const DtUUID &newUUID)
 

Protected Attributes

DtSimulationServices * mySimulationServices
 
- Protected Attributes inherited from makVrf::DtSimObjectManagerTemplate< DtSimObject >
DtStateDataManager * myStateDataManager
 
tbb::spin_rw_mutex myMutex
 
boost::signals2::scoped_connection myUUIDUpgradedConnection
 
std::vector< DtStateDataManager * > myStateDataManagerOrder
 
std::map< DtStateDataManager
*, StateDataManagerInformation > 
myStateDataManagers
 
SimObjects mySimObjects
 
AwaitingMap myAwaitingMap
 
SimObjects myAdded
 
DeletedObjects myDeleted
 
SimObjectConnections mySimObjectConnections
 

Private Member Functions

 DtSimObjectManager ()
 
 DtSimObjectManager (const DtSimObjectManager &)
 
DtSimObjectManager & operator= (const DtSimObjectManager &)
 

Additional Inherited Members

- Public Types inherited from makVrf::DtSimObjectManagerTemplate< DtSimObject >
using SimObjects = std::map< unsigned long long, DtSimObjectReferenceTemplate< DtSimObject >>
 
typedef std::set< const
DtFrameStateInterface * > 
CurrentFrameStates
 
typedef
boost::signals2::signal< void(DtStateComponent *)> 
StateComponentAddedSignal
 
typedef
boost::signals2::signal< void(DtStateComponent *)> 
StateComponentRemovedSignal
 
- Public Attributes inherited from makVrf::DtSimObjectManagerTemplate< DtSimObject >
boost::signals2::signal< void()> signal_advancedFrame
 
boost::signals2::signal< void(DtSimObjectReferenceTemplate
< DtSimObject >)> 
signal_simObjectAdded
 
boost::signals2::signal< void(DtSimObjectReferenceTemplate
< DtSimObject >)> 
signal_simObjectDeleted
 
boost::signals2::signal< void(const
DtUUID &oldUUID, const DtUUID
&newUUID)> 
signal_uuidChanged
 
boost::signals2::signal< void(const
DtUUID &oldUUID, const DtUUID
&newUUID)> 
signal_uuidUpgradedTo
 
boost::signals2::signal< void(DtSimObjectReferenceTemplate
< DtSimObject >, const
DtString &oldText, const
DtString &newText)> 
signal_simObjectRenamed
 
- Protected Types inherited from makVrf::DtSimObjectManagerTemplate< DtSimObject >
typedef std::map< DtString,
DtSimObjectReferenceTemplate
< DtSimObject > > 
AwaitingMap
 
typedef std::map< unsigned
long long, Connections > 
SimObjectConnections
 

Constructor & Destructor Documentation

DtSimObjectManager::DtSimObjectManager ( )
private
DtSimObjectManager::DtSimObjectManager ( const DtSimObjectManager &  )
private
DtSimObjectManager::DtSimObjectManager ( DtSimulationServices *  m)

CTOR – Takes the state data manager so this can be made aware of the comings and goings of state data.

virtual DtSimObjectManager::~DtSimObjectManager ( )
overridevirtual

Member Function Documentation

DtSimObjectManager& DtSimObjectManager::operator= ( const DtSimObjectManager &  )
private
virtual bool DtSimObjectManager::hasValidSimulatedEntity ( ) const
virtual

Returns true if there is a locally simulated entity or unit in this simulation.

DtSimulationServices* DtSimObjectManager::simulationServices ( )
inline
virtual DtSimObjectReferenceList DtSimObjectManager::entitiesTracking ( const DtUUID &  ) const
virtual

Given the global object designator, find all the entities that are tracking the given object by their emitter systems.

virtual DtSimObjectReferenceList DtSimObjectManager::entitiesJamming ( const DtUUID &  ) const
virtual

Given the global object designator, find all the entities that are tracking the given object by their emitter systems.

virtual makVrf::DtStateDataWrapper* DtSimObjectManager::createSimObject ( makVrf::DtStateData *  sd) const
overridevirtual

Factory method: create a sim object wrapper from an existing DtStateData instance.

Parameters
sdThe state data to wrap.
Returns
A new DtStateDataWrapper for the given state data.

Implements makVrf::DtSimObjectManagerTemplate< DtSimObject >.

virtual makVrf::DtStateDataWrapper* DtSimObjectManager::createSimObject ( const DtUUID &  uuid) const
overridevirtual

Factory method: create a sim object wrapper for the given UUID.

Parameters
uuidThe UUID of the object to create.
Returns
A new DtStateDataWrapper for the given UUID.

Implements makVrf::DtSimObjectManagerTemplate< DtSimObject >.

virtual makVrf::DtStateDataWrapper* DtSimObjectManager::createSimObject ( const DtEntityIdentifier &  entid) const
overridevirtual

Factory method: create a sim object wrapper for the given entity identifier.

Parameters
entidThe entity identifier of the object to create.
Returns
A new DtStateDataWrapper for the given entity identifier.

Implements makVrf::DtSimObjectManagerTemplate< DtSimObject >.

virtual void DtSimObjectManager::referenceAdded ( makVrf::DtSimObjectReferenceTemplate< DtSimObject >  ref)
overridevirtual

Called when a new sim object reference is added to this manager.

Parameters
refThe newly added sim object reference.

Reimplemented from makVrf::DtSimObjectManagerTemplate< DtSimObject >.

virtual void DtSimObjectManager::objectsEmbarkedOn ( const DtUUID &  ,
std::vector< DtSimObjectReference > &  list 
) const
virtual

Returns a list of all objects embarked on the given object. These are objects that are only directly embarked – not objects that are embarked on objects embarked on.

virtual void DtSimObjectManager::uuidChanged ( unsigned long  long,
const DtUUID &  oldUUID,
const DtUUID &  newUUID 
)
overrideprotectedvirtual

Member Data Documentation

DtSimulationServices* DtSimObjectManager::mySimulationServices
protected

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

Document ID: Generated on Thu Oct 15 21:27:02 EDT 2026 from SVN revision 296421
Copyright © 2005-2026 MAK Technologies. All Rights Reserved (www.mak.com)