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 | Protected Attributes
DtDefaultOwnershipHandler Class Reference

This class meant to encapsulate user callbacks on ownership management services. More...

+ Inheritance diagram for DtDefaultOwnershipHandler:
+ Collaboration diagram for DtDefaultOwnershipHandler:

Public Member Functions

 DtDefaultOwnershipHandler ()
 Constructor.
virtual ~DtDefaultOwnershipHandler ()
 Destructor.
virtual DtOwnershipHandlerclone () const
 Clone copy.
 DtDefaultOwnershipHandler (const DtDefaultOwnershipHandler &other)
 Copy constructor.
DtDefaultOwnershipHandleroperator= (const DtDefaultOwnershipHandler &other)
 Assignment operator.
virtual void setOwnershipAcquisitionAction (DtOwnershipAction)
 Set the default action when someone offers an object to acquire Your three options are, accept, deny, or send a callback to ask for this information.
virtual void setOwnershipDivestitudeAction (DtOwnershipAction)
 Set the default action when someone requests your object to acquire Your three options are, accept, deny, or send a callback to ask for this information.
virtual void gainOwnership (const RTI::AttributeHandleSet &set)
 Called whenever the local federate has acquired ownership of a set of attributes.
virtual void loseOwnership (const RTI::AttributeHandleSet &set)
 Called whenever the local federate has lost ownership of a set of attributes.
virtual void setAcquireOwnershipCallback (DtAcquireOwnershipCb cb, void *usr, const DtObjClassDesc *desc=0)
 Callback for Acquiring ownership.
virtual void setDivestOwnershipCallback (DtDivestOwnershipCb cb, void *usr, const DtObjClassDesc *desc=0)
 Callback for divesting ownership.
virtual void addAcquireOwnershipRequestCallback (DtAcquireOwnershipRequestCb cb, void *usr)
virtual void removeAcquireOwnershipRequestCallback (DtAcquireOwnershipRequestCb cb, void *usr)
virtual void addDivestOwnershipRequestCallback (DtDivestOwnershipRequestCb cb, void *usr)
virtual void removeDivestOwnershipRequestCallback (DtDivestOwnershipRequestCb cb, void *usr)
virtual bool requestAttributeOwnershipRelease (const RTI::AttributeHandleSet &candidateAttributes, const char *theTag)
 Called as a result of the requestAttributeOwnershipRelease RTI service.
virtual void requestAttributeOwnershipAssumption (const RTI::AttributeHandleSet &offeredAttributes, const char *theTag)
 Called as a result of the requestAttributeOwnershipAssumption RTI service.
- Public Member Functions inherited from DtOwnershipHandler
 DtOwnershipHandler ()
 Constructor.
virtual ~DtOwnershipHandler ()
 Destructor.
 DtOwnershipHandler (const DtOwnershipHandler &other)
 Copy constructor.
DtOwnershipHandleroperator= (const DtOwnershipHandler &other)
 Assignment operator.
virtual DtHlaObjecthlaObject ()
 Returns a pointer to the DtHlaObject with which this instance has been registered.
virtual void attributeOwnershipDivestitureNotification (const RTI::AttributeHandleSet &releasedAttributes)
 Called as a result of the attributeOwnershipDivestitureNotification RTI service.
virtual void attributeOwnershipAcquisitionNotification (const RTI::AttributeHandleSet &securedAttributes)
 Called as a result of the attributeOwnershipAcquisitionNotification RTI service.
virtual void confirmAttributeOwnershipAcquisitionCancellation (const RTI::AttributeHandleSet &attributes)
 Called as a result of the confirmAttributeOwnershipAcquisitionCancellation RTI service.

Protected Attributes

DtOwnershipAction myAcquisitionAction
DtOwnershipAction myDivestAction
std::map
< RTI::ObjectClassHandle,
DtAcquireOwnershipCbInfo
myAcquireOwnershipCbList
std::map
< RTI::ObjectClassHandle,
DtDivestOwnershipCbInfo
myDivestOwnershipCbList
DtAcquireOwnershipCbInfo myDefaultAcquireOwnershipCb
DtDivestOwnershipCbInfo myDefaultDivestOwnershipCb
std::list
< DtAcquireOwnershipRequestCbInfo
myAcquireOwnershipRequestCbList
std::list
< DtDivestOwnershipRequestCbInfo
myDivestOwnershipRequestCbList
- Protected Attributes inherited from DtOwnershipHandler
DtHlaObjectmyHlaObj

Additional Inherited Members

- Protected Member Functions inherited from DtOwnershipHandler
virtual void setHlaObject (DtHlaObject *obj)

Detailed Description

This class meant to encapsulate user callbacks on ownership management services.

It allows users to automatically accept or deny ownership requests, as well as globally register callbacks related to ownership management.

Constructor & Destructor Documentation

DtDefaultOwnershipHandler::DtDefaultOwnershipHandler ( )

Constructor.

virtual DtDefaultOwnershipHandler::~DtDefaultOwnershipHandler ( )
virtual

Destructor.

DtDefaultOwnershipHandler::DtDefaultOwnershipHandler ( const DtDefaultOwnershipHandler other)

Copy constructor.

Member Function Documentation

virtual void DtDefaultOwnershipHandler::addAcquireOwnershipRequestCallback ( DtAcquireOwnershipRequestCb  cb,
void *  usr 
)
virtual
virtual void DtDefaultOwnershipHandler::addDivestOwnershipRequestCallback ( DtDivestOwnershipRequestCb  cb,
void *  usr 
)
virtual
virtual DtOwnershipHandler* DtDefaultOwnershipHandler::clone ( ) const
virtual

Clone copy.

Reimplemented from DtOwnershipHandler.

Reimplemented in DtPartialOwnershipHandler, and DtRprOwnershipHandler.

virtual void DtDefaultOwnershipHandler::gainOwnership ( const RTI::AttributeHandleSet &  set)
virtual

Called whenever the local federate has acquired ownership of a set of attributes.

This can happen as the result of an attributeOwnershipAcquisitionNotification RTI service call.

Reimplemented from DtOwnershipHandler.

Reimplemented in DtPartialOwnershipHandler.

virtual void DtDefaultOwnershipHandler::loseOwnership ( const RTI::AttributeHandleSet &  set)
virtual

Called whenever the local federate has lost ownership of a set of attributes.

This can happen as a result of an explicit or implicit unpublish, an attributeOwnershipDivestitureNotification RTI service call, or a call to DtHlaObject::unconditionalDivest.

Reimplemented from DtOwnershipHandler.

Reimplemented in DtPartialOwnershipHandler.

DtDefaultOwnershipHandler& DtDefaultOwnershipHandler::operator= ( const DtDefaultOwnershipHandler other)

Assignment operator.

virtual void DtDefaultOwnershipHandler::removeAcquireOwnershipRequestCallback ( DtAcquireOwnershipRequestCb  cb,
void *  usr 
)
virtual
virtual void DtDefaultOwnershipHandler::removeDivestOwnershipRequestCallback ( DtDivestOwnershipRequestCb  cb,
void *  usr 
)
virtual
virtual void DtDefaultOwnershipHandler::requestAttributeOwnershipAssumption ( const RTI::AttributeHandleSet &  offeredAttributes,
const char *  theTag 
)
virtual

Called as a result of the requestAttributeOwnershipAssumption RTI service.

You can call DtHlaObject's acquireAttributes even though you are within an RTI callback.

Reimplemented from DtOwnershipHandler.

Reimplemented in DtRprOwnershipHandler.

virtual bool DtDefaultOwnershipHandler::requestAttributeOwnershipRelease ( const RTI::AttributeHandleSet &  candidateAttributes,
const char *  theTag 
)
virtual

Called as a result of the requestAttributeOwnershipRelease RTI service.

You should return true if you accept this attribute transfer, and false otherwise

Reimplemented from DtOwnershipHandler.

Reimplemented in DtRprOwnershipHandler.

virtual void DtDefaultOwnershipHandler::setAcquireOwnershipCallback ( DtAcquireOwnershipCb  cb,
void *  usr,
const DtObjClassDesc desc = 0 
)
virtual

Callback for Acquiring ownership.

These callbacks will be called whenever this federate acquires an object's attributes

virtual void DtDefaultOwnershipHandler::setDivestOwnershipCallback ( DtDivestOwnershipCb  cb,
void *  usr,
const DtObjClassDesc desc = 0 
)
virtual

Callback for divesting ownership.

These callbacks will be called whenever this federate divests an object's attributes

virtual void DtDefaultOwnershipHandler::setOwnershipAcquisitionAction ( DtOwnershipAction  )
virtual

Set the default action when someone offers an object to acquire Your three options are, accept, deny, or send a callback to ask for this information.

virtual void DtDefaultOwnershipHandler::setOwnershipDivestitudeAction ( DtOwnershipAction  )
virtual

Set the default action when someone requests your object to acquire Your three options are, accept, deny, or send a callback to ask for this information.

Member Data Documentation

std::map<RTI::ObjectClassHandle, DtAcquireOwnershipCbInfo> DtDefaultOwnershipHandler::myAcquireOwnershipCbList
protected
std::list<DtAcquireOwnershipRequestCbInfo> DtDefaultOwnershipHandler::myAcquireOwnershipRequestCbList
protected
DtOwnershipAction DtDefaultOwnershipHandler::myAcquisitionAction
protected
DtAcquireOwnershipCbInfo DtDefaultOwnershipHandler::myDefaultAcquireOwnershipCb
protected
DtDivestOwnershipCbInfo DtDefaultOwnershipHandler::myDefaultDivestOwnershipCb
protected
DtOwnershipAction DtDefaultOwnershipHandler::myDivestAction
protected
std::map<RTI::ObjectClassHandle, DtDivestOwnershipCbInfo> DtDefaultOwnershipHandler::myDivestOwnershipCbList
protected
std::list<DtDivestOwnershipRequestCbInfo> DtDefaultOwnershipHandler::myDivestOwnershipRequestCbList
protected

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

Document ID: Generated on Wed Jan 7 13:31:29 EST 2015 from SVN revision 149162
Copyright © 2005-2014 VT MÄK. All Rights Reserved (www.mak.com)