14 #include <boost/unordered_map.hpp>
15 #include <tbb/mutex.h>
19 class DtRwSpawnTemplateList;
36 virtual bool loadTemplates(
const DtFilename&
filename,
bool sendUpdate =
true);
43 virtual void updateSpawnSinkTemplates(
53 static void preScenarioLoadCallback(
DtScenario& scenario,
58 static void preScenarioRewindCallback(
void* usrData);
61 static void preScenarioImportCallback(
DtScenario& scenario,
63 virtual void preScenarioImport(
DtScenario& scenario);
66 static void postScenarioImportCallback(
const DtScenario& scenario,
68 virtual void postScenarioImport(
const DtScenario& scenario);
70 virtual DtUUID uuidForTemplateName(
const DtString& templateName)
const;
73 virtual bool addSpawnPoint(
const DtUUID& templateUuid,
const DtUUID& spawnPointUuid);
75 virtual void removeSpawnPoint(
const DtUUID& templateUuid,
const DtUUID& spawnPointUuid);
82 virtual void resetManagerTemplates(
const DtRwSpawnDataList& templates,
const DtFilename& templateFilename,
bool sendUpdates =
true);
84 virtual void clearTemplates();
92 static void requestSpawnListCallback(
DtSimMessage* msg,
void* usr);
100 static void spawnTemplateListCallback(
DtSimMessage* msg,
void* usr);
101 virtual void preocesSpawnTemplateList(
DtSimMessage* msg);
107 virtual void sendSpawnListMessage(
const DtSimulationAddress& recipient,
108 bool initialSend =
false);
113 static void addSinkPointCallback(
DtSimMessage* msg,
void* usr);
119 static void requestSpawnDataCallback(
DtSimMessage* msg,
void* usr);
120 virtual void processRequestSpawnData(
DtSimMessage* msg);
125 static void updateSpawnTemplateCallback(
DtSimMessage* msg,
void* usr);
126 virtual void processUpdateSpawnTemplate(
DtSimMessage* msg);
131 static void createTemplateCallback(
DtSimMessage* msg,
void* usr);
137 static void deleteSpawnTemplateCallback(
DtSimMessage* msg,
void* usr);
138 virtual void processDeleteSpawnTemplate(
DtSimMessage* msg);
152 virtual void processAddSpawnPoint(
const DtSimObject *
object);
166 virtual void removeSpawnTemplateAsParentOfSinkPoint(
const DtUUID& templateUUID,
const DtUUID& sinkPoint);
167 virtual void addSpawnTemplateAsParentOfSinkPoint(
const DtUUID& templateUUID,
const DtUUID& sinkPoint);
169 virtual void upgradeTemplates(
const DtRwSpawnDataList& templates,
bool andRename =
false);
171 virtual void resolveUnmatchedSpawnPoints();
175 typedef void (*DtClearTemplateUUIDFunction)(
void* userData);
176 typedef void (*DtRefreshSpawnDataFunction)(
void* userData);
178 virtual void addClearTemplateUUIDEntry(
179 DtClearTemplateUUIDFunction fcn,
void* userData);
180 virtual void removeClearTemplateUUIDEntry(
181 DtClearTemplateUUIDFunction fcn,
void* userData);
183 virtual void addRefreshSpawnDataEntry(
184 DtRefreshSpawnDataFunction fcn,
void* userData);
185 virtual void removeRefreshSpawnDataEntry(
186 DtRefreshSpawnDataFunction fcn,
void* userData);
189 virtual DtUUID uuidBasedOnName(
const DtList& templateList,
const DtString&)
const;
UUID is a unique ID wrapper class.
Definition: uuid.h:59
std::map< DtString, DtString > myNewSpawnNameToOldSpawnNameMap
Definition: spawnSinkManager.h:211
class DtLocalObjectManager:
Definition: localObjectManager.h:157
DtNoArgumentCallbackList myRefreshSpawnDataCallbackList
Definition: spawnSinkManager.h:199
Definition: rwSpawnDataList.h:25
Definition: scenario.h:52
Manages all of the spawn points, sink points, and spawn templates in the current scenario.
Definition: spawnSinkManager.h:24
WaitingForSinkPoints myWaitingForSinkPoints
Definition: spawnSinkManager.h:209
boost::signals2::scoped_connection mySimObjectAddedConnection
Definition: spawnSinkManager.h:213
DtRwSpawnDataList myTemplates
Definition: spawnSinkManager.h:195
bool myTemplatesModified
Definition: spawnSinkManager.h:202
#define DT_DLL_vrfobjcore
This file is used to determine how to build.
Definition: vrfobjcoreDefines.h:24
Base library for data that is used to control how spawn points generate entities. This data structure...
Definition: rwSpawnData.h:37
File: simMsg.h.
Definition: simMessage.h:35
boost::unordered_map< DtRwSpawnData *, DtString > myCurrentUUIDsOnImport
Definition: spawnSinkManager.h:201
This class works just as DtCalllbackTable, but manages callbacks that have no arguments, and therefore don't fit in the template defined by DtCallbackList.
Definition: noArgumentCallbackList.h:151
std::map< DtString, DtUUID > WaitingForSinkPoints
Definition: spawnSinkManager.h:208
tbb::mutex myMutex
Definition: spawnSinkManager.h:216
PointByTemplate mySpawnPoints
Definition: spawnSinkManager.h:205
Central access point of all non-object-specific the services and managers that are available for use ...
Definition: simulationServices.h:96
boost::unordered_map< DtUUID, DtUUID > PointByTemplate
Definition: spawnSinkManager.h:204
Represents a single simulation object in the exercise. Object may be VRF simulation, or non-VRF simulated, and may be simulated by the local sim engine, or by a remote sim engine. Only public (external) state of the object is available. All data is read-only. All access to data of the object is thread safe within the simulation frame.
Definition: simObject.h:80
DtSimulationServices * mySimulationServices
Definition: spawnSinkManager.h:192
PointByTemplate mySinkPoints
Definition: spawnSinkManager.h:206
DT_DLL_DEBUGDRAWRENDERER void init(makVrv::DtDe &de)
Work function for the plugin initialization.
DtNoArgumentCallbackList myClearTemplatesCallbackList
Definition: spawnSinkManager.h:198
Contains the DtSimObjectReference class declaration.
boost::signals2::scoped_connection mySimObjectDeletedConnection
Definition: spawnSinkManager.h:214
DtLocalObjectManager * myObjectManager
Definition: spawnSinkManager.h:193
A locally simulated VRF object.
Definition: localObject.h:98
DtRwSpawnDataList myCurrentTemplates
Definition: spawnSinkManager.h:196