19 #include <vlpi/metocEnums.h>
20 #include <tbb/spin_mutex.h>
28 class DtEnvironmentConditionStateRepository;
33 class DtTroposphereStateComponent;
34 class DtSubsurfaceStateComponent;
35 class DtLandSurfaceStateComponent;
36 class DtWaterSurfaceStateComponent;
37 class DtSubsurfaceStateComponent;
73 virtual void onTick()
override;
77 virtual RTI::ObjectClassHandle objectClassHandle()
const override;
81 virtual DtString type()
const override;
86 template<
typename T,
typename V>
92 removeBaseUpdateCallback();
94 setEnvironmentConditionTypeFromObject(ro);
96 myObject->baseAddPostUpdateCallback(reflectedObjectUpdateCallbackFunction,
this);
97 setUpdateReceived(
true);
98 setupFromNetworkRepository<V>();
103 virtual void clearReflectedObject(
bool shouldRemoveStateComponent =
true);
104 static void reflectedObjectUpdateCallbackFunction(
DtReflectedObject* obj,
void* userData);
110 return nextFrameVrfObject()->nextFrameState()->getStateComponent<T>();
116 return nextFrameVrfObject()->hasStateComponent<T>();
122 return nextFrameVrfObject()->addStateComponent<T>(mySimObject->isLocal(), !mySimObject->isLocal());
127 return !nextFrameVrfObject()->hasStateComponent<T>() ? createVrfStateComponent<T>() : getVrfStateComponent<T>();
130 void removeStateComponent();
138 initializeRemoteStateComponents<T>();
139 updateFromReflectedObject();
145 switch (myEnvironmentConditionType)
151 getOrCreateVrfStateComponent<DtEnvironmentalLocationStateComponent>();
152 getOrCreateVrfStateComponent<DtVrfGeometryStateComponent>();
155 myStateComponent = getOrCreateVrfStateComponent<T>();
158 virtual void updateFromReflectedObject()
override;
159 virtual int mapMetocCloudTypeToVrvCloudType(DtCloudTypeEnum32)
const;
160 virtual int mapHazeTypeToObscurant(DtHazeTypeEnum32 type)
const;
164 virtual void updateFromMetocGeoreference(
const DtEnvironmentConditionStateRepository* stateRep);
171 virtual void removeBaseUpdateCallback();
DtVrfWeatherPrecipitationType
Definition: vrfWeatherStateEnums.h:13
Definition: environmentConditionRemoteNetInterface.h:42
Definition: environmentConditionRemoteNetInterface.h:45
DtFrameStateInterface * myStateComponent
Definition: environmentConditionRemoteNetInterface.h:184
Definition: environmentConditionRemoteNetInterface.h:48
static const int DtDefaultWeatherPriority
Definition: environmentConditionRemoteNetInterface.h:194
DtEnvironmentConditionType myEnvironmentConditionType
This is important since the interface is generic, but it can be instantiated by any environment condi...
Definition: environmentConditionRemoteNetInterface.h:183
Definition: environmentConditionRemoteNetInterface.h:50
Definition: environmentConditionRemoteNetInterface.h:41
Definition: environmentConditionRemoteNetInterface.h:49
Definition: simRemoteEnvironmentalNetInterface.h:38
DtEnvironmentConditionType
Definition: environmentConditionRemoteNetInterface.h:39
Definition: environmentConditionRemoteNetInterface.h:44
Definition: environmentConditionRemoteNetInterface.h:46
class DtVrlinkNetworkInterface:
Definition: vrlinkNetworkInterface.h:72
void setReflectedObject(T *ro)
Definition: environmentConditionRemoteNetInterface.h:87
1) Define the interface class that will be used to represent the next and current frames...
Definition: waterSurfaceStateComponent.h:82
The overall structure of the DtStateData mechanism is: The DtStateData contains a list of double buff...
Definition: stateData.h:398
Definition: environmentConditionRemoteNetInterface.h:52
Class Description: DtSimObjectNetInterface.
Definition: simObjectNetInterface.h:50
tbb::spin_mutex myTroposphereLayerAltitudeByUuidMapMutex
Definition: environmentConditionRemoteNetInterface.h:196
T * createVrfStateComponent()
Definition: environmentConditionRemoteNetInterface.h:120
1) Define the interface class that will be used to represent the next and current frames...
Definition: subsurfaceStateComponent.h:111
#define DT_DLL_vrlinkNetworkInterface
This file is used to determine how to build.
Definition: vrlinkNetworkInterfaceDefines.h:24
static const int DtGlobalWeatherPriority
Definition: environmentConditionRemoteNetInterface.h:193
DtReflectedObject * myObject
Note that this is a reflected object because this class, while weather, also covers subsurface layers...
Definition: environmentConditionRemoteNetInterface.h:181
std::map< DtVrlUuid, double > DtAltitudeByUuidMapType
Definition: environmentConditionRemoteNetInterface.h:187
1) Define the interface class that will be used to represent the next and current frames...
Definition: landSurfaceStateComponent.h:88
Definition: environmentConditionRemoteNetInterface.h:43
T * getOrCreateVrfStateComponent()
Definition: environmentConditionRemoteNetInterface.h:125
T * getVrfStateComponent()
Definition: environmentConditionRemoteNetInterface.h:108
static std::unordered_map< std::string, DtEnvironmentConditionType > theHLAClassNameToEnvironmentConditionTypeMap
Definition: environmentConditionRemoteNetInterface.h:185
DtAltitudeByUuidMapType myTroposphereLayerAltitudeByUuidMap
TODO consider replacing this with just "myLastReceivedAltitude" since this class is not shared betwee...
Definition: environmentConditionRemoteNetInterface.h:189
bool hasStateComponent()
Definition: environmentConditionRemoteNetInterface.h:114
void setupFromNetworkRepository()
initializes parts of the local repository from the network state rep. This needs to be done after the...
Definition: environmentConditionRemoteNetInterface.h:133
This is a simple base class that will be used to return a pointer to current or next frame state...
Definition: stateComponent.h:294
1) Define the interface class that will be used to represent the next and current frames...
Definition: troposphereStateComponent.h:46
void initializeRemoteStateComponents()
Definition: environmentConditionRemoteNetInterface.h:143
Definition: environmentConditionRemoteNetInterface.h:47