![]() |
VR-Forces 4.0.4 Class Documentation
|
DtIffControllerComponent is a controller that manages a IFF publisher for an entity. More...

Public Member Functions | |
| DtIffControllerComponent (const DtString &name, DtVrfObject *owner, DtSimManager *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0) | |
| (const DtString&,DtVrfObject*,DtSimManager*, | |
| virtual | ~DtIffControllerComponent () |
| destructor | |
| virtual bool | init () |
| Calls setRadio() | |
| virtual void | tick () |
| Calculate new control values. | |
| virtual DtString | type () const |
| Returns a string identifies the class type of component. | |
| virtual void | registerSetIffRequestMsgCallbacks () |
| Registers its interest in set IFF request messages. | |
| virtual void | processSetIffRequestMessage (DtSimMessage *msg) |
Static Public Member Functions | |
| static DtSimComponent * | creator (const DtString &name, DtVrfObject *owner, DtSimManager *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0) |
| (const DtString&,DtVrfObject*,DtSimManager*, | |
| static void | setIffRequestCallback (DtSimMessage *msg, void *usrData) |
Protected Member Functions | |
| DtIffControllerComponent () | |
| Default constructor; should not be called. | |
| DtIffControllerComponent (const DtIffControllerComponent &orig) | |
| copy constructor; shallow; does not copy the ports. | |
| const DtIffControllerComponent & | operator= (const DtIffControllerComponent &orig) |
| assignment operator; see comments on copy constructor! | |
| virtual void | setRadio (DtSimBaseRadio *radio) |
| Override this so we can register interest in IFF messages. | |
| virtual bool | createPublisher () |
| virtual void | updateFromDescriptor () |
| Updates current state from the descriptor owned by this controller. | |
| virtual void | updateFromSetRequest (DtSetIffRequest *setReq, bool updateInPSR=true) |
| Updates current state from the specified set iff request message. | |
| virtual void | updateDynamicData () |
| Updates data that periodically updates from the entity state (i.e. Mode5 Altitude) | |
| virtual bool | needsToTick () |
| Returns true if the publisher should be ticked. | |
| virtual bool | createPSR () |
| Creates myProcessState data member, and adds it to our process state repository manager. | |
Protected Attributes | |
| DtIffPublisher * | myIffPublisher |
| bool | myHasBeenTicked |
| bool | myUseAltMode5 |
| set to true once the IFF is used for the first time. | |
| DtVrfIffPSR * | myProcessState |
| True if we are currently using alternate mode 5C. | |
| bool | myFirstTick |
DtIffControllerComponent is a controller that manages a IFF publisher for an entity.
Uses Descriptor Type: DtIffControllerDescriptor
| DtIffControllerComponent::DtIffControllerComponent | ( | const DtString & | name, |
| DtVrfObject * | owner, | ||
| DtSimManager * | simManager, | ||
| DtComponentDescriptor * | desc = 0, |
||
| DtReaderWriterRegistry * | parentRegistry = 0 |
||
| ) |
(const DtString&,DtVrfObject*,DtSimManager*,
| name | Reader writer name of this component. |
| owner | The DtVrfObject that owns this component |
| simManager | The simulation manager (provides access to terrain, message interface, simulation clock). |
| desc | The component descriptor used to initialize this component. |
| parentRegistry | Pointer to the parent reader writer registry (the containing object that reads/writes this object). |
| virtual DtIffControllerComponent::~DtIffControllerComponent | ( | ) | [virtual] |
destructor
| DtIffControllerComponent::DtIffControllerComponent | ( | ) | [protected] |
Default constructor; should not be called.
Here because the compiler will generate an unprotected one otherwise.
| DtIffControllerComponent::DtIffControllerComponent | ( | const DtIffControllerComponent & | orig | ) | [protected] |
copy constructor; shallow; does not copy the ports.
| virtual bool DtIffControllerComponent::init | ( | ) | [virtual] |
Calls setRadio()
Reimplemented from DtControllerComponent.
| virtual void DtIffControllerComponent::tick | ( | ) | [virtual] |
Calculate new control values.
Reimplemented from DtSimComponent.
| virtual DtString DtIffControllerComponent::type | ( | ) | const [virtual] |
Returns a string identifies the class type of component.
Type values are defined in compTypes.h. DtSimComponent creation functions are registered with the DtSimComponentFactory using the type values as the key.
Reimplemented from DtControllerComponent.
| static DtSimComponent* DtIffControllerComponent::creator | ( | const DtString & | name, |
| DtVrfObject * | owner, | ||
| DtSimManager * | simManager, | ||
| DtComponentDescriptor * | desc = 0, |
||
| DtReaderWriterRegistry * | parentRegistry = 0 |
||
| ) | [static] |
(const DtString&,DtVrfObject*,DtSimManager*,
| name | Reader writer name of this component. |
| owner | The DtVrfObject that owns this component |
| simManager | The simulation manager (provides access to terrain, message interface, simulation clock). |
| desc | The component descriptor used to initialize this component. |
| parentRegistry | Pointer to the parent reader writer registry (the containing object that reads/writes this object). |
| virtual void DtIffControllerComponent::registerSetIffRequestMsgCallbacks | ( | ) | [virtual] |
Registers its interest in set IFF request messages.
| static void DtIffControllerComponent::setIffRequestCallback | ( | DtSimMessage * | msg, |
| void * | usrData | ||
| ) | [static] |
| virtual void DtIffControllerComponent::processSetIffRequestMessage | ( | DtSimMessage * | msg | ) | [virtual] |
| const DtIffControllerComponent& DtIffControllerComponent::operator= | ( | const DtIffControllerComponent & | orig | ) | [protected] |
assignment operator; see comments on copy constructor!
| virtual void DtIffControllerComponent::setRadio | ( | DtSimBaseRadio * | radio | ) | [protected, virtual] |
Override this so we can register interest in IFF messages.
Reimplemented from DtControllerComponent.
| virtual bool DtIffControllerComponent::createPublisher | ( | ) | [protected, virtual] |
| virtual void DtIffControllerComponent::updateFromDescriptor | ( | ) | [protected, virtual] |
Updates current state from the descriptor owned by this controller.
| virtual void DtIffControllerComponent::updateFromSetRequest | ( | DtSetIffRequest * | setReq, |
| bool | updateInPSR = true |
||
| ) | [protected, virtual] |
Updates current state from the specified set iff request message.
| virtual void DtIffControllerComponent::updateDynamicData | ( | ) | [protected, virtual] |
Updates data that periodically updates from the entity state (i.e. Mode5 Altitude)
| virtual bool DtIffControllerComponent::needsToTick | ( | ) | [protected, virtual] |
Returns true if the publisher should be ticked.
The publisher is not ticked if all the IFF modes are off, and have never been turned on. Once any mode is turned on, the publisher is always ticked, even if the mode is later turned off.
| virtual bool DtIffControllerComponent::createPSR | ( | ) | [protected, virtual] |
Creates myProcessState data member, and adds it to our process state repository manager.
Passes in the name and type specified in the component descriptor (if they exist) to the DtVrfProcessStateRepository::createRepository factory method. If name and/or type is not specified, uses the appropriate default strings defined in procSRTypes.h.
DtIffPublisher* DtIffControllerComponent::myIffPublisher [protected] |
bool DtIffControllerComponent::myHasBeenTicked [protected] |
bool DtIffControllerComponent::myUseAltMode5 [protected] |
set to true once the IFF is used for the first time.
DtVrfIffPSR* DtIffControllerComponent::myProcessState [protected] |
True if we are currently using alternate mode 5C.
Container for state data associated with this component. This state is saved and restored as part of a scenario (or checkpoint).
bool DtIffControllerComponent::myFirstTick [protected] |