VR-Forces Developer's Guide
 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 | Static Protected Attributes | Private Member Functions
DtVrfObjectIdGenerator Class Reference

This class will, in DIS or HLA, generate the unique id necessary to pass into the object publisher to describe the id of that object. When creating a published object, it is important to use this class to generate the id that can be used as a valid object identifier for VR-Forces. This class is used internally by the VR-Forces object publishers when assigning new object ids.

Public Member Functions

 DtVrfObjectIdGenerator ()
 
virtual ~DtVrfObjectIdGenerator ()
 
virtual DtGlobalObjectDesignator nextId (DtExerciseConn *, DtEntityIdentifier &)
 

Static Public Member Functions

static DtVrfObjectIdGeneratorobjectIdGenerator ()
 
static void setObjectIdGenerator (DtVrfObjectIdGenerator *)
 
static bool isVrfGlobalId (const DtGlobalObjectDesignator &identifier)
 
static void setVrfDISAppIdRange (int iLower, int iUpper)
 
static DtGlobalObjectDesignator nullId ()
 

Static Protected Attributes

static DtVrfObjectIdGeneratortheDefaultObjectIdGenerator
 
static int theDisAppIdLower
 
static int theDisAppIdUpper
 

Private Member Functions

 DtVrfObjectIdGenerator (const DtVrfObjectIdGenerator &)
 
DtVrfObjectIdGeneratoroperator= (const DtVrfObjectIdGenerator &)
 

Constructor & Destructor Documentation

DtVrfObjectIdGenerator::DtVrfObjectIdGenerator ( )
virtual DtVrfObjectIdGenerator::~DtVrfObjectIdGenerator ( )
virtual
DtVrfObjectIdGenerator::DtVrfObjectIdGenerator ( const DtVrfObjectIdGenerator )
private

Member Function Documentation

virtual DtGlobalObjectDesignator DtVrfObjectIdGenerator::nextId ( DtExerciseConn *  ,
DtEntityIdentifier &   
)
virtual

Override this method to return your next id. In DIS this will return the next id of the exercise connection/ In HLA, it will be VRF prepended onto an HLA object id.

Returns the next available object identifier that is used when creating an object to be published on the network. Note that in DIS, the entity identifier and the global object designator returned are the same value. In HLA these values are different

static DtVrfObjectIdGenerator* DtVrfObjectIdGenerator::objectIdGenerator ( )
static

Returns the global factory that is used when generating new object identifiers for VR-Forces. If no generator is set, then, uses a default generator of this class type.

static void DtVrfObjectIdGenerator::setObjectIdGenerator ( DtVrfObjectIdGenerator )
static
static bool DtVrfObjectIdGenerator::isVrfGlobalId ( const DtGlobalObjectDesignator identifier)
static

Returns true if given global object Id is a VR-Forces encoded global Id and false if it is not.

static void DtVrfObjectIdGenerator::setVrfDISAppIdRange ( int  iLower,
int  iUpper 
)
static

Sets the DIS app id range to use when determining if something is published by VRF or not Currently this range is 3000 - 4000.

static DtGlobalObjectDesignator DtVrfObjectIdGenerator::nullId ( )
inlinestatic
DtVrfObjectIdGenerator& DtVrfObjectIdGenerator::operator= ( const DtVrfObjectIdGenerator )
private

Member Data Documentation

DtVrfObjectIdGenerator* DtVrfObjectIdGenerator::theDefaultObjectIdGenerator
staticprotected
int DtVrfObjectIdGenerator::theDisAppIdLower
staticprotected
int DtVrfObjectIdGenerator::theDisAppIdUpper
staticprotected

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

Document ID: Generated on Tue Sep 24 19:28:17 EDT 2024 from SVN revision 269799
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)