20 #include <boost/signals2.hpp>
24 namespace makVrfEvents
26 class DtServiceRequestEvent;
27 class DtResupplyReceivedEvent;
50 virtual const char*
type()
const;
64 static void setSupplyingCallback(
DtSimMessage * msg,
void * usr);
73 virtual void addSetDataCallbacks();
77 void removeSetDataCallbacks();
126 void transferSupplies();
127 virtual void processReadyState(
const DtUUID& receiver);
128 void processOfferingState(
const DtUUID& receiver);
131 virtual void updateOfferedSupplies(
const DtUUID& receiver);
133 virtual void removeSentSupplies(
const DtUUID& receiver);
134 virtual bool checkSuppliesRequested(
const DtUUID& receiver);
135 virtual bool checkResourcesAvailable(
const DtUUID& receiver);
136 virtual bool checkResourceAvailable(
const DtEntityType& type);
137 virtual bool checkResourceAvailable(
const DtString& supplyName);
138 virtual double resourceAvailable(
const DtEntityType& type);
139 virtual double resourceAvailable(
const DtString& supplyName);
140 virtual void updateResource(
const DtEntityType& type,
double quantity);
141 virtual void updateResource(
const DtString& supplyName,
double quantity);
143 virtual const DtString lookUpSupplyType(
const DtEntityType& type)
const;
145 virtual DtTime currentSimTime();
163 const DtTime theOfferingStateDefaultTimeout = 120.0;
UUID is a unique ID wrapper class.
Definition: rwUUID.h:229
#define DT_DLL_vrfmodel
This file is used to determine how to build.
Definition: vrfmodelDefines.h:24
Definition: resupplyReceivedEvent.h:14
This class provides a base class for all controllers that are capable of executing a DtSimTask...
Definition: singleTaskControllerComponent.h:20
A readable, writable type whose name is the name of a component and that has a list of component name...
Definition: componentDescriptor.h:49
Definition: readerWriterRegistry.h:39
virtual const char * type() const =0
Returns a string identifies the class type of component. Type values are defined in compTypes...
virtual bool init()
Calls setRadio()
boost::signals2::scoped_connection myServiceRequestEventConnection
Definition: resupplySupplierController.h:154
const DtResupplySupplierControllerDescriptor * myResupplySupplierDesc
Controller descriptor.
Definition: resupplySupplierController.h:149
Definition: resupplyOfferEvent.h:14
Definition: resupplyCancelEvent.h:13
File: simMsg.h.
Definition: simMessage.h:35
virtual void tick()
This gives the thread of control to the component. The component is ticked once each simulation from ...
Central access point of all non-object-specific the services and managers that are available for use ...
Definition: simulationServices.h:90
The DtSimComponent class is the base class for the entire simulation model component hierarchy...
Definition: simComponent.h:70
const DtTaskControllerComponent & operator=(const DtTaskControllerComponent &orig)
assignment operator
This class implements a controller, which gives the unit the capability to provide supplies...
Definition: resupplySupplierController.h:33
boost::signals2::scoped_connection myResupplyReceivedEventConnection
Definition: resupplySupplierController.h:155
Definition: serviceRequestEvent.h:14
virtual bool postAddComponentsInit()
Calls enableTaskTypes()
DtResupplySupplierControllerDescriptor is a DtComponentDescriptor that has additional information nee...
Definition: resupplySupplierControllerDescriptor.h:20
boost::signals2::scoped_connection myResupplyCancelEventConnection
Definition: resupplySupplierController.h:156
std::map< DtUUID, DtResupplySupplierStateData > mySupplierStateData
Controller state transition class.
Definition: resupplySupplierController.h:152
A locally simulated VRF object. Holds all internal and external data for the object, and provides access to both the current frame and next frame state data for the object. All current frame data is read-only, and next-frame data can be written to. No thread safety guarantees are made on this object during the simulation frame and it should only be accessed by the thread that is simulating the object.
Definition: localObject.h:86