20 : myUUID(
DtUUID::nullUUID())
56 DtEntityIdentifier myEntityId;
58 unsigned long long myUserData = 0;
59 unsigned long long myObjectId = 0;
70 : DtSimulatedObjectStateComponent(storage)
90 virtual const DtUUID& orbatUUID()
const override;
92 virtual const int orbatOrder()
const override;
93 virtual void setOrbatOrder(
const int&)
override;
95 virtual const unsigned long long& objectId()
const override;
96 virtual void setObjectId(
const unsigned long long&)
override;
101 virtual const DtUUID& parent()
const override;
102 virtual void setParent(
const DtUUID&)
override;
109 virtual const bool& isLocal()
const override;
110 virtual void setIsLocal(
const bool&)
override;
112 virtual const bool& checkForNameReservation()
const override;
113 virtual void setCheckForNameReservation(
const bool&)
override;
115 virtual const DtEntityIdentifier& entityId()
const override;
116 virtual void setEntityId(
const DtEntityIdentifier&)
override;
118 virtual const DtString& globalId()
const override;
119 virtual void setGlobalId(
const DtString&)
override;
121 virtual const UInt32 appearanceBits()
const override;
123 virtual const DtString& label()
const override;
124 virtual void setLabel(
const DtString&)
override;
126 virtual const DtUUID& uuid()
const override;
127 virtual void setUUID(
const DtUUID& u)
override;
129 virtual const DtString& markingText()
const override;
130 virtual void setMarkingText(
const DtString&)
override;
132 virtual const DtForceType forceType()
const override;
133 virtual void setForceType(
const DtForceType&)
override;
135 virtual const DtEntityType
entityType()
const override {
return objectType(); };
136 virtual const DtEntityType objectType()
const override;
137 virtual void setEntityType(
const DtEntityType& t)
override;
138 virtual const DtSimulationAddress simEngineAddress()
const override;
140 virtual const unsigned long long userLongLongData()
const override;
141 virtual void setUserLongLongData(
const unsigned long long&)
override;
144 virtual void makeWritable()
override;
147 virtual void makeReadOnly()
override;
159 virtual const UInt32 appearanceBits()
const override;
160 virtual const unsigned long long& objectId()
const override;
161 virtual const bool& checkForNameReservation()
const override;
162 virtual const bool& isLocal()
const override;
163 virtual const DtUUID& orbatUUID()
const override;
164 virtual const int orbatOrder()
const override;
165 virtual const DtString& label()
const override;
166 virtual const DtUUID& parent()
const override;
167 virtual const DtEntityIdentifier& entityId()
const override;
168 virtual const DtString& globalId()
const override;
169 virtual const DtUUID& uuid()
const override;
170 virtual const DtString& markingText()
const override;
171 virtual const DtForceType forceType()
const override;
172 virtual const DtEntityType
entityType()
const override {
return objectType(); };
173 virtual const DtEntityType objectType()
const override;
174 virtual const unsigned long long userLongLongData()
const override;
175 virtual const DtSimulationAddress simEngineAddress()
const override;
206 if (myNextFrameState.isWritable())
208 myCurrentFrameState.advanceFrame(myNextFrameState.frameState());
211 myCurrentFrameState.emitComponentUpdated();
216 myCurrentFrameState.updateStateData(sd);
217 myNextFrameState.updateStateData(sd);
223 myCurrentFrameState.aboutToBeDeleted();
224 myNextFrameState.aboutToBeDeleted();
227 virtual void convertToLocal()
override;
228 virtual void convertToRemote()
override;
3) Define the current frame class. This will be used for read access.
Definition: orbatStateComponent.h:154
UUID is a unique ID wrapper class.
Definition: uuid.h:59
const DtRwOrbatData & data() const
Definition: orbatStateComponent.h:39
unsigned int UInt32
Definition: stateDataTypes.h:18
Definition: stateComponent.h:269
The DtSimulatedObjectStateComponent is an interface that all main components (those that are consider...
Definition: simulatedObjectStateComponent.h:21
virtual DtFrameStateInterface * nextFrameState() override
Definition: orbatStateComponent.h:201
0) Define the State Component Data. This struct replaces the legion stuff
Definition: orbatStateComponent.h:17
virtual const DtEntityType entityType() const override
Definition: orbatStateComponent.h:135
#define UNDEFINED_RETURNREF_ACCESSOR(ReturnType, Member)
Definition: doubleBufferedDataStorage.h:34
const DtOrbatStateComponentData & frameState() const
Definition: orbatStateComponent.h:107
DtRwOrbatData & data()
Definition: orbatStateComponent.h:44
virtual void updateDataStorage() override
Implement to update data storage. Called from advanceFrame.
Definition: orbatStateComponent.h:204
DtOrbatStateComponentData myData
Definition: orbatStateComponent.h:150
DtOrbatStateComponentData(const DtOrbatStateComponentData &orig)
Definition: orbatStateComponent.h:24
1) Define the interface class that will be used to represent the next and current frames...
Definition: orbatStateComponent.h:64
virtual bool mainComponentOnLegion() const override
Definition: orbatStateComponent.h:81
Definition: stateComponent.h:69
void advanceFrame(const DtOrbatStateComponentData &data)
Definition: orbatStateComponent.h:182
The overall structure of the DtStateData mechanism is: The DtStateData contains a list of double buff...
Definition: stateData.h:398
#define DEFINE_STATE_COMPONENT_TYPE(CreatedComponent)
Definition: stateComponent.h:231
Definition: rwOrbatData.h:20
virtual const DtFrameStateInterface * currentFrameState() const override
Definition: orbatStateComponent.h:200
DtUUID myUUID
Definition: orbatStateComponent.h:55
Subclass from this to indicate that this will be a double buffered state component.
Definition: stateComponent.h:384
DtOrbatStateComponentData myData
Definition: orbatStateComponent.h:188
#define UNDEFINED_RETURNVALUE_ACCESSOR_MUTATOR(Type, Member, Set)
Definition: doubleBufferedDataStorage.h:53
DtOrbatStateComponentCurrentFrame myCurrentFrameState
Definition: orbatStateComponent.h:231
DtOrbatStateComponentData()
Definition: orbatStateComponent.h:19
virtual void aboutToBeDeleted()
2) Define the next frame class. This will be used for write access.
Definition: orbatStateComponent.h:85
virtual void aboutToBeDeleted() override
Definition: orbatStateComponent.h:220
DtOrbatStateComponentNextFrame myNextFrameState
Definition: orbatStateComponent.h:232
#define UNDEFINED_RETURNREF_ACCESSOR_MUTATOR(Type, Member, Set)
Definition: doubleBufferedDataStorage.h:57
#define DEFINE_ACCESSOR_MUTATOR(ReturnType, Accessor, Mutator)
Definition: doubleBufferedDataStorage.h:23
unsigned long long myObjectId
Definition: orbatStateComponent.h:59
bool isDoubleBuffered()
Definition: orbatStateComponent.h:199
DtOrbatStateComponentData & operator=(const DtOrbatStateComponentData &orig)
Definition: orbatStateComponent.h:29
DtStateComponentCreator< DtOrbatStateComponentImplementation > DtOrbatStateComponentCreator
5) Define the creator. This will need to be registered with the REGISTER_STATE_COMPONENT macro in the...
Definition: orbatStateComponent.h:237
DtRwOrbatData myData
Definition: orbatStateComponent.h:57
virtual const DtFrameStateInterface * nextFrameState() const override
Definition: orbatStateComponent.h:202
4) Define the state component that will contain the wrappers to the next and current frame states tha...
Definition: orbatStateComponent.h:193
#define DT_DLL_vrfStateData
This file is used to determine how to build Disable inconsistent dll linkage warning Visual Studio 6...
Definition: vrfStateDataDefines.h:26
virtual const DtEntityType entityType() const override
Definition: orbatStateComponent.h:172
virtual void updateStateData(DtStateData *sd) override
Implement to update data storage to the new state data.
Definition: orbatStateComponent.h:214
Contains the DtStateComponent class declaration.
This is a simple base class that will be used to return a pointer to current or next frame state...
Definition: stateComponent.h:294
DtOrbatStateComponentData & frameState()
Next frame access write access. Ensure this is only used in a single thread (i.e.a controller thread)...
Definition: orbatStateComponent.h:106
unsigned long long myUserData
Definition: orbatStateComponent.h:58