VR-Link API Documentation for HLA 1.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Static Public Member Functions | Protected Attributes
DtCollisionInteraction Class Reference

Instances of DtCollisionInteraction are used to represent Collision Interactions in the RPR FOM. More...

+ Inheritance diagram for DtCollisionInteraction:
+ Collaboration diagram for DtCollisionInteraction:

Public Member Functions

 DtCollisionInteraction ()
 default constructor More...
 
virtual ~DtCollisionInteraction ()
 destructor More...
 
 DtCollisionInteraction (const DtCollisionInteraction &orig)
 copy constructor More...
 
DtCollisionInteractionoperator= (const DtCollisionInteraction &orig)
 assignment operator More...
 
virtual void printData () const
 Print the interaction's data to DtInfo. More...
 
virtual void printDataToStream (std::ostream &stream) const
 Print the interaction's data to the specified stream. More...
 
virtual void setIssueId (const DtGlobalObjectDesignator &id)
 Set/Get the issuer identifier. More...
 
virtual const
DtGlobalObjectDesignator
issueId () const
 
virtual void setCollideId (const DtGlobalObjectDesignator &id)
 Set/Get the collide identifier. More...
 
virtual const
DtGlobalObjectDesignator
collideId () const
 
virtual void setEventId (const DtEventID &id)
 Set/Get the collision event id. More...
 
virtual const DtEventIDeventId () const
 
virtual void setCollisionType (DtCollisionType t)
 Set/Get the collision type. More...
 
virtual DtCollisionType collisionType () const
 
virtual void setVelocity (const DtVector &veloc)
 Set/Get the velocity. More...
 
virtual const DtVectorvelocity () const
 
virtual void setMass (DtFloat32 mass)
 Set/Get the mass involved. More...
 
virtual DtFloat32 mass () const
 
virtual void setEntityCoords (const DtVector &coords)
 Set/Get the entity coordinates. More...
 
virtual const DtVectorentityCoords () const
 
virtual const char * name () const
 Name of the interaction. (Not necessarily the ClassName from the FOM.) More...
 
- Public Member Functions inherited from DtInteractionWithEncDec
 DtInteractionWithEncDec ()
 default constructor More...
 
virtual ~DtInteractionWithEncDec ()
 destructor More...
 
 DtInteractionWithEncDec (const DtInteractionWithEncDec &orig)
 copy constructor More...
 
DtInteractionWithEncDecoperator= (const DtInteractionWithEncDec &orig)
 assignment operator More...
 
virtual void setExConn (DtExerciseConn *exConn, DtInterClassDesc *classDesc=NULL)
 Sets the interaction's ExerciseConn and class descriptor. More...
 
virtual const
RTI::ParameterHandleValuePairSet & 
phvps () const
 Get the parameter handle value pair set for the interaction. More...
 
virtual void setFromPhvps (const RTI::ParameterHandleValuePairSet &pvList)
 Set contents from a parameter handle value pair set. More...
 
virtual void useThese (DtInteractionEncoder *enc, DtInteractionDecoder *dec, DtInteractionRep *data)
 Specify an encoder, decoder, and interaction data repository to use in encoding and decoding. More...
 
virtual DtInteractionEncoderencoder () const
 Return the encoder we are using. More...
 
virtual DtInteractionDecoderdecoder () const
 Return the decoder we are using. More...
 
virtual void setParameterByHandle (const RTI::ParameterHandle &attrHdl, const char *attrValue, unsigned size)
 Set the Parameter with the given handle. More...
 
virtual const char * getParameterByHandle (const RTI::ParameterHandle &attrHdl, unsigned &size) const
 Get a pointer to Parameter value for the Parameter with the given handle. More...
 
virtual void setParameterByName (const DtString &name, const char *attrValue, unsigned size)
 Set the Parameter with the given name. More...
 
virtual const char * getParameterByName (const DtString &name, unsigned &size) const
 Get a pointer to Parameter value for the Parameter with the given name. More...
 
- Public Member Functions inherited from DtInteraction
 DtInteraction ()
 default constructor More...
 
virtual ~DtInteraction ()
 destructor More...
 
 DtInteraction (const DtInteraction &orig)
 copy constructor More...
 
DtInteractionoperator= (const DtInteraction &orig)
 assignment operator More...
 
virtual RTI::InteractionClassHandle interactionClassHandle () const
 Get the interaction class handle. Returns 0 if no classDesc. More...
 
virtual char * interactionClassName () const
 Get the interaction class name. Returns NULL if no classDesc. More...
 
virtual int numParameters () const
 Get the number of parameters. Returns 0 if no classDesc. More...
 
virtual bool neededByFederation () const
 Returns true if the interaction class is needed by the federation false otherwise. More...
 
virtual void print () const
 Print the interaction's host rep data, including header. More...
 
virtual void printToStream (std::ostream &stream) const
 Print the interaction to a stream. More...
 
virtual void printHeader () const
 Print the header info. More...
 
virtual void printHeaderToStream (std::ostream &stream) const
 Print the header info to a stream. More...
 
virtual void printDataToString (DtString &buff) const
 Print the interaction's data to the string provided. More...
 
virtual void printParams (bool withHex) const
 Print the header followed by the interaction's parameters. More...
 
virtual void printParamsToStream (std::ostream &stream, bool withHex) const
 Print the header followed by the interaction's parameters to a stream. More...
 
virtual DtExerciseConnexerciseConn () const
 Get the current exercise connection. More...
 
virtual DtInterClassDescclassDesc () const
 Get the current class descriptor we're using for this interaction. More...
 
virtual bool customTagSet () const
 Get whether a custom tag has been set on the interaction or not. More...
 
virtual void setCustomTag (const DtString &a_tag)
 Set the user-defined tag. More...
 
virtual void setTag (const DtString &tag)
 Set the user-defined tag. More...
 
virtual const DtStringtag () const
 Get the user-defined tag. More...
 
virtual const RTI::Region * conveyedRegion () const
 Get & Set the conveyed region of the reflected state message. More...
 
virtual void setConveyedRegion (const RTI::Region *region)
 
virtual void setTimeStamp (DtTime time, DtTimeStampType type=DtTimeStampRelative)
 Set the time of validity of the message, and whether this represents relative or absolute time. More...
 
virtual DtTime timeStamp () const
 Return the time of validity of the message (in seconds past an hour) as set by setTimeStamp. More...
 
virtual DtTimeStampType timeStampType () const
 Return the type of the time stamp. More...
 
virtual DtTime guessTimeValid (DtTime referenceTime) const
 Since timestamp only represents number of seconds past the hour, guessTimeValid chooses the hour that would make the timestamp closest to reference time, and returns a time that is timestamp seconds past that hour. More...
 
virtual void setFedTime (const RTI::FedTime &ft)
 This is used for TSO interactions. More...
 
virtual const RTI::FedTime * fedTime () const
 When the interaction is received, if the federate sending the interaction had TSO set then the fedTime will be set. More...
 
virtual void setEventRetractionHandle (const RTI::EventRetractionHandle &handle)
 Get/Set the EventRetractionHandle. More...
 
virtual RTI::EventRetractionHandle eventRetractionHandle () const
 Get the event retraction handle. For more info see setEventRetractionHandle. More...
 

Static Public Member Functions

static DtInteractioncreate ()
 Create a DtCollisionInteraction. More...
 
static void addCallback (DtExerciseConn *conn, DtCollisionInteractionCb cb, void *usr, DtDDMRegionSP region=DtDDMRegionSP())
 Add (register)/Remove (deregister) function to be called when interaction occurs. More...
 
static void removeCallback (DtExerciseConn *conn, DtCollisionInteractionCb cb, void *usr, DtDDMRegionSP region=DtDDMRegionSP())
 
- Static Public Member Functions inherited from DtInteraction
static void setTagIsAsciiTime (bool val)
 Set/Get flag that tells us whether we're using the RPR FOM convention that the UserDefinedTag in updates and interactions represents a DIS-style timestamp. More...
 
static bool tagIsAsciiTime ()
 
static void addCallback (DtExerciseConn *conn, const std::vector< DtString > *classes, DtReceiveInteractionCb cb, void *usr, DtDDMRegionSP region=DtDDMRegionSP())
 Register/Deregister callback function cb with conn, on all interaction class name (char*) contained in classes. More...
 
static void removeCallback (DtExerciseConn *conn, const std::vector< DtString > *classes, DtReceiveInteractionCb cb, void *usr, DtDDMRegionSP region=DtDDMRegionSP())
 
static void addCallback (DtExerciseConn *conn, const char *className, DtReceiveInteractionCb cb, void *usr, DtDDMRegionSP region=DtDDMRegionSP())
 Can be used instead of above for a single class. More...
 
static void removeCallback (DtExerciseConn *conn, const char *className, DtReceiveInteractionCb cb, void *usr, DtDDMRegionSP region=DtDDMRegionSP())
 

Protected Attributes

DtGlobalObjectDesignator myIssueId
 
DtGlobalObjectDesignator myCollideId
 
DtEventID myEventId
 
DtCollisionType myCollisionType
 
DtVector myVelocity
 
DtFloat32 myMass
 
DtVector myEntityCoords
 
- Protected Attributes inherited from DtInteractionWithEncDec
DtInteractionDecodermyDecoder
 
DtInteractionEncodermyEncoder
 
DtInteractionRep * myData
 
std::map< RTI::ParameterHandle,
DtGenericParameterInfo * > 
myParametersByHandle
 parameters by handle. More...
 
- Protected Attributes inherited from DtInteraction
DtInterClassDescmyClassDesc
 
DtExerciseConnmyExConn
 
DtTime myTime
 
DtTimeStampType myTimeType
 
DtString myTag
 
RTI::ParameterHandleValuePairSet * myPvList
 
int myPvListMaxSize
 
RTI::FedTime * myFedTime
 
RTI::EventRetractionHandle myRetractionHandle
 
const RTI::Region * myConveyedRegion
 
bool myCustomTagSet
 

Additional Inherited Members

- Protected Member Functions inherited from DtInteractionWithEncDec
virtual DtInteractionDecodercreateDecoder (DtExerciseConn *exConn) const
 Called by decoderToUse to obtain a new'ed decoder. More...
 
virtual DtInteractionEncodercreateEncoder (DtExerciseConn *exConn) const
 Called by encoderToUse to obtain a new'ed encoder. More...
 
virtual DtInteractionDecoderdecoderToUse (DtExerciseConn *exConn) const
 Returns a decoder to use for decoding the interaction. More...
 
virtual DtInteractionEncoderencoderToUse (DtExerciseConn *exConn) const
 Returns an encoder to use for encoding the interaction. More...
 
- Protected Member Functions inherited from DtInteraction
virtual const char * interactionClassToUse (DtExerciseConn *exConn) const
 Returns the FOM interaction class name to use. More...
 
virtual
RTI::ParameterHandleValuePairSet * 
privPvList () const
 Returns a pointer to a private pvList that can be used as a return value by phvps. More...
 
DtInteractionself () const
 Get rid of const-ness on the "this" pointer in order to access non-const functions from const member functions (such as simple accessors). More...
 
- Static Protected Attributes inherited from DtInteraction
static bool theTagIsAsciiTime
 

Detailed Description

Instances of DtCollisionInteraction are used to represent Collision Interactions in the RPR FOM.

Constructor & Destructor Documentation

DtCollisionInteraction::DtCollisionInteraction ( )

default constructor

virtual DtCollisionInteraction::~DtCollisionInteraction ( )
virtual

destructor

DtCollisionInteraction::DtCollisionInteraction ( const DtCollisionInteraction orig)

copy constructor

Member Function Documentation

static void DtCollisionInteraction::addCallback ( DtExerciseConn conn,
DtCollisionInteractionCb  cb,
void *  usr,
DtDDMRegionSP  region = DtDDMRegionSP() 
)
static

Add (register)/Remove (deregister) function to be called when interaction occurs.

virtual const DtGlobalObjectDesignator& DtCollisionInteraction::collideId ( ) const
virtual
virtual DtCollisionType DtCollisionInteraction::collisionType ( ) const
virtual
static DtInteraction* DtCollisionInteraction::create ( )
static

Create a DtCollisionInteraction.

Caller is responsible for deletion.

virtual const DtVector& DtCollisionInteraction::entityCoords ( ) const
virtual
virtual const DtEventID& DtCollisionInteraction::eventId ( ) const
virtual
virtual const DtGlobalObjectDesignator& DtCollisionInteraction::issueId ( ) const
virtual
virtual DtFloat32 DtCollisionInteraction::mass ( ) const
virtual
virtual const char* DtCollisionInteraction::name ( ) const
virtual

Name of the interaction. (Not necessarily the ClassName from the FOM.)

Implements DtInteraction.

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

assignment operator

virtual void DtCollisionInteraction::printData ( ) const
virtual

Print the interaction's data to DtInfo.

Reimplemented from DtInteraction.

virtual void DtCollisionInteraction::printDataToStream ( std::ostream &  stream) const
virtual

Print the interaction's data to the specified stream.

Reimplemented from DtInteraction.

static void DtCollisionInteraction::removeCallback ( DtExerciseConn conn,
DtCollisionInteractionCb  cb,
void *  usr,
DtDDMRegionSP  region = DtDDMRegionSP() 
)
static
virtual void DtCollisionInteraction::setCollideId ( const DtGlobalObjectDesignator id)
virtual

Set/Get the collide identifier.

virtual void DtCollisionInteraction::setCollisionType ( DtCollisionType  t)
virtual

Set/Get the collision type.

virtual void DtCollisionInteraction::setEntityCoords ( const DtVector coords)
virtual

Set/Get the entity coordinates.

virtual void DtCollisionInteraction::setEventId ( const DtEventID id)
virtual

Set/Get the collision event id.

virtual void DtCollisionInteraction::setIssueId ( const DtGlobalObjectDesignator id)
virtual

Set/Get the issuer identifier.

virtual void DtCollisionInteraction::setMass ( DtFloat32  mass)
virtual

Set/Get the mass involved.

virtual void DtCollisionInteraction::setVelocity ( const DtVector veloc)
virtual

Set/Get the velocity.

virtual const DtVector& DtCollisionInteraction::velocity ( ) const
virtual

Member Data Documentation

DtGlobalObjectDesignator DtCollisionInteraction::myCollideId
protected
DtCollisionType DtCollisionInteraction::myCollisionType
protected
DtVector DtCollisionInteraction::myEntityCoords
protected
DtEventID DtCollisionInteraction::myEventId
protected
DtGlobalObjectDesignator DtCollisionInteraction::myIssueId
protected
DtFloat32 DtCollisionInteraction::myMass
protected
DtVector DtCollisionInteraction::myVelocity
protected

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

Document ID: Generated on Mon Apr 25 03:39:01 EDT 2022 from SVN revision 242502
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)