VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
DtGlobalEnvironmentObjectRepository Class Reference

This class creates a network state repository to aid sending tactical smoke objects. More...

Inheritance diagram for DtGlobalEnvironmentObjectRepository:
Inheritance graph
[legend]

Public Member Functions

 DtGlobalEnvironmentObjectRepository ()
 
 DtGlobalEnvironmentObjectRepository (const DtGlobalEnvironmentObjectRepository &)
 
virtual void sendUpdateWhenTimeChangesBy (double)
 When the time of day changes by this amount send an update. Default is 1 second. More...
 
virtual double updateWhenTimeChangesBy () const
 
- Public Member Functions inherited from DtWeatherObjectRepository
 DtWeatherObjectRepository ()
 
 DtWeatherObjectRepository (const DtWeatherObjectRepository &)
 
virtual bool sendNeeded (const DtEnvironmentProcessRepository &asSeenByRemote)
 
void setClock (DtClock *clock)
 
DtClockclock () const
 
double lastUpdateTime () const
 
void setLastUpdateTime (DtTime t)
 
- Public Member Functions inherited from DtControlObjectRepository
 DtControlObjectRepository ()
 default constructor More...
 
virtual ~DtControlObjectRepository ()
 destructor More...
 
 DtControlObjectRepository (const DtControlObjectRepository &orig)
 copy constructor More...
 
virtual bool isInitialized () const
 Returns true if one of the initialize() functions has been called. More...
 
DtControlObjectRepositoryoperator= (const DtControlObjectRepository &orig)
 assignment operator More...
 
virtual int compare (const DtControlObjectRepository *rhs)
 Compares us against the supplied state repository and returns what's changed. More...
 
virtual const DtRwPropertiesstateProperties () const
 
virtual const DtRwPropertiesparameterProperties () const
 
virtual void setUuidString (const DtString &uuidStr)
 
virtual DtString uuidString () const
 Returns a string version of the VRF UUID of this object, if it can be determined. More...
 
void mapPropertiesToRecordTypes (const DtRwProperties *properties, std::map< unsigned, DtString > &recTypesToAttrNames)
 Maps properties to DIS record types, if configured. Called from constructors. More...
 
virtual void updateExtensions ()
 Overridden to update property data. More...
 
virtual bool updatePropertiesFromAttributes (bool updatesOnly=true)
 Updates properties with new data from the extended attributes. More...
 
virtual void updateAttributesFromProperties ()
 Updates extended attributes from our properties. More...
 
virtual void addPropertyDecoder (const DtString &propName, PropertyDecoder decoder, void *usr)
 Adds an additional property and a function that to decode it. More...
 
virtual void addPropertyEncoder (const DtString &propName, PropertyEncoder encoder, void *usr)
 Adds an additional property and a function that to encode it. More...
 
virtual void removePropertyEncodersAndDecoders ()
 Removes all additional property encoders and decoders. More...
 
virtual bool createVrfObjectDataMessage ()
 Allocates myVrfObjectDataMessage, a DtIfVrfObjectData used by VR-Forces as extended VRF object data message information. More...
 
virtual void giveOwernshipOfProperties ()
 Tells the state rep to take ownership of the state and parameter properties, giving it responsibility to delete them on destruction. More...
 
virtual DtTime lastPropertyEncodeTime () const
 Last time properties were encoded. More...
 
virtual DtTime lastPropertyDecodeTime () const
 Last time properties were decoded. More...
 
virtual void initialize (DtRwProperties *stateProps, DtRwProperties *paramProps)
 
virtual void initialize (const DtRwProperties &stateProps, const DtRwProperties &paramProps)
 Initializes the state rep by making a copy of the given state properties and parameter properties that have have already been initialized. More...
 
virtual void initialize ()
 Initializes the state rep without any state or parameter properties. More...
 
virtual bool sensorsKilled () const
 Functions for accessing the sensors killed state. More...
 
virtual void setSensorsKilled (bool killed)
 
virtual void addPropertyUpdatedCallback (DtNoArgumentCallbackList::DtCallbackFunctionType fcn, void *usrData)
 Callbacks invoked just after state and parameter properties have been updated when the parameter or state properties have been updated. More...
 
virtual void removePropertyUpdatedCallback (DtNoArgumentCallbackList::DtCallbackFunctionType fcn, void *usrData)
 
- Public Member Functions inherited from DtControlObjectBaseRepository
 DtControlObjectBaseRepository ()
 default constructor More...
 
virtual ~DtControlObjectBaseRepository ()
 destructor More...
 
 DtControlObjectBaseRepository (const DtControlObjectBaseRepository &orig)
 copy constructor More...
 
DtControlObjectBaseRepositoryoperator= (const DtControlObjectBaseRepository &orig)
 assignment operator More...
 
virtual const DtControlObjectKindkind () const
 
virtual void setKind (const DtControlObjectKind &k)
 
virtual const
DtControlObjectCategory
category () const
 
virtual void setCategory (const DtControlObjectCategory &c)
 
const std::vector< DtVector > & vertexList () const
 
virtual int compare (const DtControlObjectBaseRepository *rhs)
 Compares us against the supplied state repository and returns what's changed. More...
 
virtual int compareToMostRecent ()
 Returns what has changed since the last time we called compare. More...
 
virtual bool locationsDifferent (bool updateIfDifferent)
 Returns true if our stashed location is different than our current location. More...
 
virtual void emptyVertexList ()
 
virtual void getBoundingVolume (DtVector &location, double &radius) const
 
const DtGeometricDataListgeometricRecords () const
 
bool geometricRecordsChanged () const
 
void clearGeometricRecordsChanged ()
 
virtual void updateDataRecords ()
 If myNeedVrfObjectDataUpdate is true, update the vrf object data record. More...
 
virtual int numberOfSubordinates () const
 Subordinate information. Not currently used by VRF. More...
 
virtual bool getSubordinate (int i, DtGlobalObjectDesignator &d)
 
virtual const
DtGlobalObjectDesignatorList & 
subordinates () const
 
virtual
DtGlobalObjectDesignatorList & 
subordinates ()
 
virtual void setExtendedData (const std::map< DtString, DtString > &ed)
 Sets extended data for transport via extended data records. More...
 
virtual void setExtendedData (const DtString &key, const DtString &value)
 
virtual double orientation () const
 Returns the orientation of the given environmental in radians. More...
 
virtual void setVertices (const DtList &pnt)
 Sets the vertices to use in the publication of this object. More...
 
virtual void appendVertex (const DtVector &)
 
virtual void setVertex (int i, const DtVector &)
 
virtual void removeVertex (int i)
 
virtual void setObjectType (const DtObjectType &)
 Environmental record settings. More...
 
virtual DtForceType forceType () const
 Returns the force type from the environmental header record (if it exists), else returns neutral by default. More...
 
virtual void setForceType (DtForceType i)
 
virtual int color () const
 Returns the color (rgb) value of this object. More...
 
virtual void setColor (int)
 
virtual const DtStringparent () const
 Returns the parent of this object. More...
 
virtual void setParent (const DtString &)
 
virtual const DtStringuserData () const
 
virtual void setUserData (const DtString &)
 
virtual void setVrfObjectName (const DtString &)
 
virtual const DtStringvrfObjectName ()
 
virtual DtAppearance appearance () const
 
virtual void setAppearance (const DtAppearance &app)
 
virtual void setNumberOfSubordinates (int)
 
virtual void setSubordinate (int i, const DtGlobalObjectDesignator &)
 
virtual const
DtGlobalObjectDesignator
hostGlobalId () const
 Returns the parent this object might be attached to. More...
 
virtual void setHostGlobalId (const DtGlobalObjectDesignator &)
 
virtual void clearHostGlobalId ()
 Sets host global id to empty string. More...
 
virtual bool getFontInformation (DtString &font, int &fontSize) const
 Deals with font and arrow head information via the extended data. More...
 
virtual void setFontInformation (const DtString &, int fontSize)
 
virtual bool getFontColor (unsigned int &color) const
 32 bit AGBR value More...
 
virtual void setFontColor (unsigned int color)
 
virtual bool getArrowInformation (int &arrowHeadPlacement, int &arrowStyle, int &arrowSize) const
 
virtual void setArrowInformation (int arrowHeadPlacement, int arrowStyle, int arrowSize)
 
virtual void setBoundingSphereRadius (double)
 Routines that are used to set/get information about the bounding sphere. More...
 
virtual double boundingSphereRadius () const
 
virtual void setBoundingSphereLocation (const DtVector &)
 Sets/gets the bounding sphere location. More...
 
virtual const DtVectorboundingSphereLocation () const
 
bool hasBoundingSphereRecord () const
 
bool hasBoundingRectRecord () const
 Routines that are used to set/get information about the bounding rectangle. More...
 
virtual void setBoundingExtent (const DtVector &)
 
const DtVectorboundingExtent () const
 
virtual void setBoundingCornerLocation (const DtVector &)
 
virtual const DtVectorboundingCornerLocation () const
 
virtual void setBoundingOrientation (const DtTaitBryan &)
 
const DtTaitBryan & boundingOrientation () const
 
virtual void setProjected (bool)
 Gets/sets additional attribute values about the environmental. More...
 
virtual bool projected () const
 
virtual void setClosedFigure (bool)
 
virtual bool closedFigure () const
 
virtual void setBound2D (bool)
 
virtual bool bound2D () const
 
virtual void setFillStyle (int)
 For those objects that support it. Note that point objects do not make use of these items. More...
 
virtual int fillStyle () const
 
virtual void setLineStyle (int)
 
virtual int lineStyle () const
 
virtual void setLineWidth (int)
 
virtual int lineWidth () const
 
virtual void setPhysicalLineHeight (double)
 Height of the line, in meters. When added to the altitude, can be considered a ceiling. More...
 
virtual double physicalLineHeight () const
 
virtual void setPhysicalLineWidth (double)
 Width of the line, in meters. Different than "lineWidth" which is more of a stylistic representation. More...
 
virtual double physicalLineWidth () const
 
virtual void setRelativeLocation (const DtVector &)
 If attached to an entity, the relative position (in body coordinatates) of this object from the origin of the attached object. More...
 
virtual const DtVectorrelativeLocation () const
 
virtual void setVelocity (const DtVector &)
 Unused at this point – left for future possible expansion for movable/rotatable environmentals { More...
 
virtual const DtVectorvelocity () const
 
virtual void setAcceleration (const DtVector &)
 
virtual const DtVectoracceleration () const
 
virtual void setDRAlogrithm (DtDeadReckonTypes)
 
virtual const DtDeadReckonTypes & drAlgorithm () const
 
virtual void setOffsetPoints (const std::vector< DtVector > &)
 
virtual const std::vector
< DtVector > & 
offsetPoints () const
 
virtual void setCachePoints (bool)
 Set cachePoints to false to not cache the points that are set into the structure or read from the network into the myVertexList variable. More...
 
bool cachePoints () const
 
virtual DtString extendedData (const DtString &key) const
 Extended record data is a key/value pair. More...
 
const DtVrfExtendedRecordDataextendedRecordData () const
 
DtVrfExtendedRecordDataextendedRecordData ()
 
int numberOfDatumRecords () const
 
void setNumberOfDatumRecords (int)
 
virtual void setSendVrfObjectDataRecord (bool shouldSend)
 Whether a separate VrfObjectData record should be sent to convey additional VRF object information. More...
 
virtual bool shouldSendVrfObjectDataRecord () const
 
- Public Member Functions inherited from DtVrfExtensions
 DtVrfExtensions ()
 
virtual ~DtVrfExtensions ()
 
 DtVrfExtensions (const DtVrfExtensions &orig)
 
DtVrfExtensionsoperator= (const DtVrfExtensions &orig)
 
virtual const DtStringname () const
 
virtual void setName (const DtString &n)
 
virtual const DtStringvrfObjectLabel () const
 
virtual void setVrfObjectLabel (const DtString &l)
 
virtual const DtStringechelonId () const
 
virtual void setEchelonId (const DtString &l)
 
virtual const DtStringoverlayParent () const
 
virtual void setOverlayParent (const DtString &l)
 
virtual bool isVrfSimulated () const
 
virtual void setIsVrfSimulated (bool vrf)
 
virtual DtU32 vrfSessionId () const
 
virtual void setVrfSessionId (DtU32 id)
 
virtual void setVrfMessageVersionSupported (DtU32 id)
 
virtual DtU32 vrfMessageVersionSupported () const
 
virtual const DtObjectTypeobjectType () const
 
virtual void setIsSubordinateOfForce (bool b)
 
virtual bool isSubordinateOfForce () const
 
virtual int superType () const
 
virtual void setHasPlan (bool yesNo)
 
virtual bool hasPlan () const
 
virtual void setIsCurrentlyTasked (bool yesNo)
 
virtual bool isCurrentlyTasked () const
 
virtual void setRulesOfEngagement (const DtString &)
 
virtual const DtStringrulesOfEngagement () const
 
virtual bool setupFromVrfObjectData (const DtIfVrfObjectData &data)
 
virtual void addRangeItem (const DtRangeItem &)
 Adds, removes and returns items in the range item list. More...
 
virtual void removeRangeItem (int index)
 
virtual void setRangeItems (const DtRangeItems &)
 
const DtRangeItemsrangeItems () const
 
virtual DtIfVrfObjectDatavrfObjectDataMessage () const
 
virtual void setIndependentlyTasked (bool yesNo)
 
virtual bool independentlyTasked () const
 
virtual void setUnderFire (bool yesNo)
 
virtual bool underFire () const
 
virtual void setExecutingPlan (bool yesNo)
 
virtual bool executingPlan () const
 
virtual const std::map
< DtString, DtString > & 
extendedData () const
 
virtual void setBoundingVolume (const DtVector32 &)
 Sets/gets bounding volume and bounding volume offset of an entity. More...
 
virtual const DtVector32 & boundingVolume () const
 
virtual void setBoundingVolumeOffset (const DtVector32 &)
 
virtual const DtVector32 & boundingVolumeOffset () const
 

Static Public Member Functions

static
DtEnvironmentProcessRepository
create ()
 
- Static Public Member Functions inherited from DtWeatherObjectRepository
static
DtEnvironmentProcessRepository
create ()
 
- Static Public Member Functions inherited from DtControlObjectRepository
static
DtEnvironmentProcessRepository
create ()
 
- Static Public Member Functions inherited from DtControlObjectBaseRepository
static void initializePuffFactory ()
 Adds mappings between environmental record types and the type of information to read off of the network into local environmental data structures. More...
 
static void addToPuffFactory (int iRecordType, DtIttSourceDataCreator fcn)
 
static DtIttSourceDatacreatePuffRecord (DtNetEnvironmentalRecord *geometric, DtNetEnvironmentalRecord *source)
 
static DtIttSourceDatacreatePuffRecord (DtNetEnvironmentalRecord *rec)
 
static
DtEnvironmentProcessRepository
create ()
 
- Static Public Member Functions inherited from DtVrfExtensions
static void setExpectedVrfMessageVersion (DtU32 version)
 The expected VRF message version of this application. More...
 
static DtU32 expectedVrfMessageVersion ()
 

Protected Member Functions

virtual bool sendRecordsNeeded (const DtEnvironmentProcessRepository &asSeenByRemote)
 
virtual bool sendTimeUpdateNeeded (DtTime dt, DtNetEnvironmentalRecord *rec, DtNetEnvironmentalRecord *recRemote)
 
virtual DtStateRepositoryclone (bool copy) const
 Return a copy/empty object of the same type as this. More...
 
- Protected Member Functions inherited from DtWeatherObjectRepository
virtual bool sendWeatherRecNeeded (DtTime dt, DtNetEnvironmentalRecord *rec, DtNetEnvironmentalRecord *recRemote)
 
virtual bool sendV3WeatherRecNeeded (DtTime dt, DtNetEnvironmentalRecord *rec, DtNetEnvironmentalRecord *recRemote)
 
virtual bool sendNetRecNeeded (DtNetEnvironmentalRecord *rec1, DtNetEnvironmentalRecord *rec2)
 
- Protected Member Functions inherited from DtControlObjectRepository
virtual void initializeVrfObjectDataProperties ()
 Initializes the state rep to handle VRF object data properties. More...
 
virtual void encodePropertyIfNeeded (const DtSymbolString &propName, DtReaderWriter *propRw)
 Encode a particular property if an update is needed. More...
 
- Protected Member Functions inherited from DtControlObjectBaseRepository
virtual bool createExtendedEnvironmentalStateRecord ()
 createExtendedEnvironmentalStateRecord() allocates myExtEnvStateRecord, a DtSimEnvironmentalObjectStateRecord used by VR-Forces as extended environmental process state information: More...
 
virtual
DtSimEnvironmentalObjectStateRecord
extendedEnvironmentalStateRecord ()
 extendedEnvironmentalStateRecord() returns the myExtEnvStateRecord for inspection by the caller. More...
 
virtual bool createVrfObjectStateRecord ()
 createVrfObjectStateRecord() allocates myVrfObjectStateRecord, a DtVrfObjectDataEnvironmentalRecord used by VR-Forces as extended vrf object state information: More...
 
virtual
DtVrfObjectDataEnvironmentalRecord
vrfObjectStateRecord ()
 extendedVrfObjectStateRecord() returns the myVrfObjectStateRecord for inspection by the caller. More...
 
virtual bool createBoundingSphereRecord ()
 createBoundingSphereRecord() allocates myBoundingSphereRecord More...
 
virtual
DtEnvironmentalBoundingSphereRecord * 
boundingSphereRecord ()
 boundingSphereRecord() returns the myBoundingSphereRecord for inspection by the caller. More...
 
virtual bool createBoundingRectRecord ()
 createBoundingRectRecord() allocates myBoundingRectRecord More...
 
virtual
DtEnvironmentalRectangularVolumeRecord * 
boundingRectRecord ()
 boundingRectRecord() returns the myBoundingRectRecord for inspection by the caller. More...
 
virtual void setupKindFromType (const DtEntityType &type)
 Sets up internal object kind and category from object type. More...
 
virtual void getBoundingVolume (EnvGeomSpheriod *rec)
 
virtual void clearGeometricRecords ()
 
virtual void extensionModified ()
 Override to set myNeedVrfObjectDataUpdate to true. More...
 

Protected Attributes

double myUpdateWhenTimeChangesBy
 
- Protected Attributes inherited from DtWeatherObjectRepository
DtClockmyClock
 
DtTime myLastUpdateTime
 
- Protected Attributes inherited from DtControlObjectRepository
DtRwPropertiesmyStateProperties
 
DtRwPropertiesmyParameterProperties
 
DtEntityType myLastCheckedEnvType
 
bool myOwnsProperties
 
bool myIsInitialized
 
std::list< PropertyDecoderInfomyAdditionalDecoders
 
std::list< PropertyEncoderInfomyAdditionalEncoders
 
std::vector< charmyPropertyBuffer
 
DtClock myClock
 
DtTime myLastEncodeTime
 
DtTime myLastDecodeTime
 
bool mySensorsKilled
 
bool myReceivedVrfObjectDataVersion
 
bool myReceivedVrfPropertyVersion
 
int myPropertyVersion
 
DtString myUUIDString
 
std::map< DtString, DtStringmyExtendedDataCache
 
DtRangeItems myRangeItemsCache
 
DtNoArgumentCallbackList myPropertyUpdatedCallbacks
 
- Protected Attributes inherited from DtVrfExtensions
DtString myName
 
DtIfVrfObjectDatamyVrfObjectDataMessage
 

Additional Inherited Members

- Public Types inherited from DtControlObjectRepository
typedef void(* PropertyDecoder )(const char *buffer, unsigned size, int version, void *usr)
 
typedef void(* PropertyEncoder )(std::vector< char > &buffer, void *usr)
 
- Public Types inherited from DtControlObjectBaseRepository
typedef std::vector< DtVectorDtCOVertexList
 
typedef std::vector
< DtIttEnvironmentalProcessData * > 
DtGeometricDataList
 
typedef std::map< int,
DtIttSourceDataCreator
DtIttSourceDataMap
 
- Public Attributes inherited from DtControlObjectBaseRepository
DtControlObjectKind myKind
 
DtControlObjectCategory myCategory
 
DtCOVertexList myVertexList
 Keeps a list of all geometry point records to use to update internal model datas from. More...
 
DtSimEnvironmentalObjectStateRecordmyExtEnvStateRecord
 DtSimEnvironmentalObjectStateRecord is a special form of DtEnvironmentalRecord, used to decode custom data that might be published from a VR-Forces back end, such as label, force type, appearance, etc. More...
 
DtEnvironmentalBoundingSphereRecord * myBoundingSphereRecord
 
DtVrfObjectDataEnvironmentalRecordmyVrfObjectStateRecord
 
DtControlObjectBaseRepositorymyLastCopy
 
DtEnvironmentalRectangularVolumeRecord * myBoundingRectRecord
 
DtGeometricDataList myGeometricRecords
 
bool myGeometricRecordsChanged
 
bool myNeedVrfObjectDataUpdate
 
bool myCachePoints
 
int myPointsSet
 
DtEnvironmentalProcessExtendedRecordData myExtendedRecordData
 
bool mySendVrfObjectDataRec
 
- Static Public Attributes inherited from DtControlObjectBaseRepository
static DtIttSourceDataMap thePuffFactory
 This information is needed for ITT puff clouds. More...
 
- Static Protected Attributes inherited from DtVrfExtensions
static DtU32 theExpectedVrfMessageVersion
 

Detailed Description

This class creates a network state repository to aid sending tactical smoke objects.

Constructor & Destructor Documentation

DtGlobalEnvironmentObjectRepository::DtGlobalEnvironmentObjectRepository ( )
DtGlobalEnvironmentObjectRepository::DtGlobalEnvironmentObjectRepository ( const DtGlobalEnvironmentObjectRepository )

Member Function Documentation

static DtEnvironmentProcessRepository* DtGlobalEnvironmentObjectRepository::create ( )
static
virtual void DtGlobalEnvironmentObjectRepository::sendUpdateWhenTimeChangesBy ( double  )
virtual

When the time of day changes by this amount send an update. Default is 1 second.

virtual double DtGlobalEnvironmentObjectRepository::updateWhenTimeChangesBy ( ) const
virtual
virtual bool DtGlobalEnvironmentObjectRepository::sendRecordsNeeded ( const DtEnvironmentProcessRepository asSeenByRemote)
protectedvirtual

Reimplemented from DtWeatherObjectRepository.

virtual bool DtGlobalEnvironmentObjectRepository::sendTimeUpdateNeeded ( DtTime  dt,
DtNetEnvironmentalRecord *  rec,
DtNetEnvironmentalRecord *  recRemote 
)
protectedvirtual
virtual DtStateRepository* DtGlobalEnvironmentObjectRepository::clone ( bool  copy) const
protectedvirtual

Return a copy/empty object of the same type as this.

Reimplemented from DtWeatherObjectRepository.

Member Data Documentation

double DtGlobalEnvironmentObjectRepository::myUpdateWhenTimeChangesBy
protected

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

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)