VR-Forces 4.0.4 Class Documentation
Public Member Functions | Static Public Member Functions | Protected Attributes
DtMissileDistractionPSR Class Reference

class DtMissileDistractionPSR: More...

Inheritance diagram for DtMissileDistractionPSR:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 DtMissileDistractionPSR (DtVrfObject *vrfObject, const DtString &rwName=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=0)
 constructor
 DtMissileDistractionPSR (const DtMissileDistractionPSR &orig, const DtString &rwName=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=0)
 copy constructor
virtual ~DtMissileDistractionPSR ()
 destructor
DtMissileDistractionPSRoperator= (const DtMissileDistractionPSR &orig)
 assignment operator - not implemented
virtual
DtVrfProcessStateRepository
clone (const DtString &rwName=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=0) const
 returns a newly created copy of this object
virtual DtString type () const
 Returns the string type of the repository, as defined in procSRTypes.h.
virtual bool init ()
 Call after creation.
virtual void setAmDistracted (bool fooled)
 Set to true when the missile encounters a counter measure that has succeeded in fooling it and it retargets to go after the counter measure instead of its original target.
virtual bool amDistracted () const
virtual const std::set
< DtString > & 
verifiedDistractionsList () const
 The list of countermeasure object names that have been checked and verified by the missile that they did not distract it.
virtual bool findCounterMeasure (const DtString &objectName) const
 Returns true if the countermeasure is on the verified list.
virtual void addCounterMeasure (const DtString &objectName)
virtual void removeCounterMeasure (const DtString &objectName)
virtual void clearVerifiedDistractionsList ()
 Empties the verified Distractions List.
virtual void putSelf (FILE *fp, int indentLevel=0, bool writeUnspecified=false, const DtFilename &path=DtReaderWriter::appPath())
 Override to call mapTargetIdsToTargetNames() before calling base class version to write ourselves to file.
virtual void getSelf (DtlObjPtr args, const DtFilename &searchPath, const DtVariableBindingsList &variableBindings)
 Override to set flag indicating we should map target names to target identifiers the next time lookupPreviousTarget() is called.

Static Public Member Functions

static
DtVrfProcessStateRepository
creator (const DtString &rwName, DtVrfObject *vrfObject, DtReaderWriterRegistry *parentRegistry)
 Returns a newly created instance of this class.

Protected Attributes

DtRwBoolean myAmDistracted
 Keep track if the missile has been distracted and has retargeted.
std::set< DtStringmyVerifiedDistractionsList
 This list keeps track of which countermeasures have already been tested and found to not distract the missile away from the target.
DtRwStringList mySerializableVerifiedDistractionsList

Detailed Description

class DtMissileDistractionPSR:

Instances of DtMissileDistractionPSR are used to hold the shared/checkpointable state data for the DtMissileDistraction class.


Constructor & Destructor Documentation

DtMissileDistractionPSR::DtMissileDistractionPSR ( DtVrfObject vrfObject,
const DtString rwName = DtString::nullString(),
DtReaderWriterRegistry parentRegistry = 0 
)

constructor

DtMissileDistractionPSR::DtMissileDistractionPSR ( const DtMissileDistractionPSR orig,
const DtString rwName = DtString::nullString(),
DtReaderWriterRegistry parentRegistry = 0 
)

copy constructor

destructor


Member Function Documentation

DtMissileDistractionPSR& DtMissileDistractionPSR::operator= ( const DtMissileDistractionPSR orig)

assignment operator - not implemented

virtual DtVrfProcessStateRepository* DtMissileDistractionPSR::clone ( const DtString rwName = DtString::nullString(),
DtReaderWriterRegistry parentRegistry = 0 
) const [virtual]

returns a newly created copy of this object

Implements DtVrfProcessStateRepository.

virtual DtString DtMissileDistractionPSR::type ( ) const [virtual]

Returns the string type of the repository, as defined in procSRTypes.h.

Implements DtVrfProcessStateRepository.

virtual bool DtMissileDistractionPSR::init ( ) [virtual]

Call after creation.

Reimplemented from DtVrfProcessStateRepository.

virtual void DtMissileDistractionPSR::setAmDistracted ( bool  fooled) [virtual]

Set to true when the missile encounters a counter measure that has succeeded in fooling it and it retargets to go after the counter measure instead of its original target.

virtual bool DtMissileDistractionPSR::amDistracted ( ) const [virtual]
virtual const std::set<DtString>& DtMissileDistractionPSR::verifiedDistractionsList ( ) const [virtual]

The list of countermeasure object names that have been checked and verified by the missile that they did not distract it.

virtual bool DtMissileDistractionPSR::findCounterMeasure ( const DtString objectName) const [virtual]

Returns true if the countermeasure is on the verified list.

virtual void DtMissileDistractionPSR::addCounterMeasure ( const DtString objectName) [virtual]
virtual void DtMissileDistractionPSR::removeCounterMeasure ( const DtString objectName) [virtual]

Empties the verified Distractions List.

virtual void DtMissileDistractionPSR::putSelf ( FILE *  fp,
int  indentLevel = 0,
bool  writeUnspecified = false,
const DtFilename &  path = DtReaderWriter::appPath() 
) [virtual]

Override to call mapTargetIdsToTargetNames() before calling base class version to write ourselves to file.

It fills out our writable list of target object names from the non-writable myPreviousTargets list of DtEntityIdentifiers. This way the identities of previously detected targets get preserved as part of a checkpoint save.

Reimplemented from DtReaderWriter.

virtual void DtMissileDistractionPSR::getSelf ( DtlObjPtr  args,
const DtFilename &  searchPath,
const DtVariableBindingsList variableBindings 
) [virtual]

Override to set flag indicating we should map target names to target identifiers the next time lookupPreviousTarget() is called.

Reimplemented from DtVrfProcessStateRepository.

static DtVrfProcessStateRepository* DtMissileDistractionPSR::creator ( const DtString rwName,
DtVrfObject vrfObject,
DtReaderWriterRegistry parentRegistry 
) [static]

Returns a newly created instance of this class.


Member Data Documentation

Keep track if the missile has been distracted and has retargeted.

If this is the case, we don't need to keep evaluateing the other countermeasures. We've already been fooled.

This list keeps track of which countermeasures have already been tested and found to not distract the missile away from the target.

Stores the object name of the countermeasure.


The documentation for this class was generated from the following file:

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)