MAK RTIspy API Documentation for HLA Evolved
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
DtSyncPointMsg Class Reference
+ Inheritance diagram for DtSyncPointMsg:
+ Collaboration diagram for DtSyncPointMsg:

List of all members.

Public Member Functions

 DtSyncPointMsg (DtBufferPtr buffer=DtUSE_INTERNAL_BUFFER)
 Constructor.
 DtSyncPointMsg (DtSyncMsgType kind, DtFederateHandle id, DtSyncPointStatus statusValue, char const *name, char const *tag, const DtFederateHandleSet *set=NULL, const DtFederateHandleSet *unsuccessfulSet=NULL, DtBufferPtr buffer=DtUSE_INTERNAL_BUFFER)
 DtSyncPointMsg (const DtNetSyncMsg *netRepMsg, DtBufferPtr buffer=DtUSE_INTERNAL_BUFFER)
 Constructor.
virtual ~DtSyncPointMsg ()
 Deconstructor.
virtual DtRtiMsgclone (bool copy=true) const
 Return a copy/empty object of the same type as this.
virtual void set (DtSyncMsgType kind, DtFederateHandle id, DtSyncPointStatus statusValue, char const *name, char const *tag, DtFederateHandleSet const *set=NULL, DtFederateHandleSet const *unsuccessfulSet=NULL)
 Set all fields simultaneously.
virtual void setSyncMsgKind (DtSyncMsgType kind)
 Set/Get synchronization message kind.
virtual DtSyncMsgType syncMsgKind () const
virtual void setFederateId (DtFederateHandle id)
 Set/Get federate id.
virtual DtFederateHandle federateId () const
virtual void setSyncPointStatus (DtSyncPointStatus statusValue)
 Set/Get sync point status.
virtual DtSyncPointStatus syncPointStatus () const
virtual void setSyncPointName (char const *name)
 Set/Get synchronization point name.
virtual char const * syncPointName () const
virtual void setTag (char const *tag)
 Set/Get tag.
virtual char const * tag () const
virtual void setFederates (const DtFederateHandleSet *set)
 Set the set of federate handles to be encoded in the message.
virtual DtFederateHandleSet const * federates () const
 Returns the set of federates encoded in the message.
virtual void getFederates (DtFederateHandleSet *set) const
 Alternate way to get the set of federates contained in the message.
virtual int numFederates () const
 Get number of federates.
virtual void getUnsuccessfulFederates (DtFederateHandleSet *set) const
 Alternate way to get the set of federates contained in the message.
virtual void setUnsuccessfulFederates (const DtFederateHandleSet *set)
 Set the set of unsuccessfully synched federate handles to be encoded in the message.
virtual DtFederateHandleSet const * unsuccessfulFederates () const
 Returns the set of unsuccessfully synched federates encoded in the message.
virtual int numUnsuccessfulFederates () const
 Get number of unsuccessfully synched federates.
virtual void printData (DtLogicalTimeFactory *logicalTimeFactory) const
 Print the data section.

Static Public Member Functions

static DtRtiMsgcreate (const DtNetMsgHeader *initial, DtBufferPtr buffer=DtUSE_INTERNAL_BUFFER)
 Creator.
static DtRtiMsgcreate (DtBufferPtr buffer=DtUSE_INTERNAL_BUFFER)
 Creator.
static void addCallback (DtConnectionMgr *conn, DtSyncPointCb cb, void *usr)
 Callback management.
static void removeCallback (DtConnectionMgr *conn, DtSyncPointCb cb, void *usr)

Protected Member Functions

virtual DtNetSyncMsgnetSyncMsg ()
 The network representation.
virtual const DtNetSyncMsgnetSyncMsg () const
virtual DtNetU32 * handleArray ()
 Pointers to various fields of the net message.
virtual DtNetU32 * unsuccessfulHandleArray ()
virtual char * tagPtr ()
virtual char * namePtr ()
virtual int handleArraySize () const
 Sizes of various fields of the net message.
virtual int unsuccessfulHandleArraySize () const
virtual int tagFieldSize () const
virtual int nameFieldSize () const
virtual DtRtiMsgKind internalDtRtiMsgKind ()
 Returns the kind of a synchronization msg.
virtual int minSize () const
 Returns the minimum size of a message, including the header.
DtSyncPointMsgself () const
 Casts away constness. Use with caution.

Protected Attributes

char * myTag
MAKRti::DtString myName
DtFederateHandleSetmySet
DtFederateHandleSetmyUnsuccessfulSet

Constructor & Destructor Documentation

DtSyncPointMsg::DtSyncPointMsg ( DtBufferPtr  buffer = DtUSE_INTERNAL_BUFFER)

Constructor.

References DtRtiMsg::initDtRtiMsg(), internalDtRtiMsgKind(), and minSize().

Referenced by clone(), and create().

DtSyncPointMsg::DtSyncPointMsg ( DtSyncMsgType  kind,
DtFederateHandle  id,
DtSyncPointStatus  statusValue,
char const *  name,
char const *  tag,
const DtFederateHandleSet set = NULL,
const DtFederateHandleSet unsuccessfulSet = NULL,
DtBufferPtr  buffer = DtUSE_INTERNAL_BUFFER 
)
DtSyncPointMsg::DtSyncPointMsg ( const DtNetSyncMsg netRepMsg,
DtBufferPtr  buffer = DtUSE_INTERNAL_BUFFER 
)

Constructor.

References DtNetSyncMsg::header, and DtRtiMsg::initDtRtiMsg().

Deconstructor.

References mySet, and myTag.


Member Function Documentation

void DtSyncPointMsg::addCallback ( DtConnectionMgr conn,
DtSyncPointCb  cb,
void *  usr 
) [static]
DtRtiMsg * DtSyncPointMsg::clone ( bool  copy = true) const [virtual]

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

Implements DtRtiMsg.

References DtSyncPointMsg(), and netSyncMsg().

DtRtiMsg * DtSyncPointMsg::create ( const DtNetMsgHeader initial,
DtBufferPtr  buffer = DtUSE_INTERNAL_BUFFER 
) [static]

Creator.

References DtSyncPointMsg().

DtRtiMsg * DtSyncPointMsg::create ( DtBufferPtr  buffer = DtUSE_INTERNAL_BUFFER) [static]

Creator.

References DtSyncPointMsg().

DtFederateHandleSet const * DtSyncPointMsg::federates ( ) const [virtual]

Returns the set of federates encoded in the message.

The object returned is a reference to internal memory, and is only valid until the next time federates() is called.

References getFederates(), mySet, NULL, and numFederates().

Referenced by DtFedExec::createSyncPoint(), printData(), DtFedExec::processRegisterSyncPoint(), and DtRtiExecFederateMgr::processSyncPointMsg().

void DtSyncPointMsg::getFederates ( DtFederateHandleSet set) const [virtual]

Alternate way to get the set of federates contained in the message.

After this call, set will contain the appropriate federate set. Make sure that set is large enough to hold numFederates() handles.

References handleArray(), and numFederates().

Referenced by federates(), and DtRtiExecFederateMgr::processSyncPointMsg().

Alternate way to get the set of federates contained in the message.

After this call, set will contain the appropriate federate set. Make sure that set is large enough to hold numFederates() handles.

References numUnsuccessfulFederates(), and unsuccessfulHandleArray().

Referenced by DtRtiExecFederateMgr::processSyncPointMsg(), and unsuccessfulFederates().

DtNetU32 * DtSyncPointMsg::handleArray ( ) [protected, virtual]

Pointers to various fields of the net message.

References netSyncMsg().

Referenced by getFederates(), setFederates(), and unsuccessfulHandleArray().

int DtSyncPointMsg::handleArraySize ( ) const [protected, virtual]

Sizes of various fields of the net message.

References netSyncMsg(), and DtNetSyncMsg::numHandles.

Referenced by unsuccessfulHandleArray().

Returns the kind of a synchronization msg.

Implements DtRtiMsg.

References DtSyncPointMsgKind.

Referenced by DtSyncPointMsg().

int DtSyncPointMsg::minSize ( ) const [protected, virtual]

Returns the minimum size of a message, including the header.

Referenced by DtSyncPointMsg().

int DtSyncPointMsg::nameFieldSize ( ) const [protected, virtual]
char * DtSyncPointMsg::namePtr ( ) [protected, virtual]

References tagFieldSize(), and tagPtr().

Referenced by setSyncPointName().

DtNetSyncMsg * DtSyncPointMsg::netSyncMsg ( ) [protected, virtual]
const DtNetSyncMsg * DtSyncPointMsg::netSyncMsg ( ) const [protected, virtual]
int DtSyncPointMsg::numFederates ( ) const [virtual]

Get number of unsuccessfully synched federates.

References netSyncMsg(), and DtNetSyncMsg::numUnsuccessfulHandles.

Referenced by getUnsuccessfulFederates(), setUnsuccessfulFederates(), and unsuccessfulFederates().

void DtSyncPointMsg::printData ( DtLogicalTimeFactory logicalTimeFactory) const [virtual]
void DtSyncPointMsg::removeCallback ( DtConnectionMgr conn,
DtSyncPointCb  cb,
void *  usr 
) [static]
DtSyncPointMsg * DtSyncPointMsg::self ( ) const [inline, protected]

Casts away constness. Use with caution.

void DtSyncPointMsg::set ( DtSyncMsgType  kind,
DtFederateHandle  id,
DtSyncPointStatus  statusValue,
char const *  name,
char const *  tag,
DtFederateHandleSet const *  set = NULL,
DtFederateHandleSet const *  unsuccessfulSet = NULL 
) [virtual]

Set/Get federate id.

References DtNetSyncMsg::id, and netSyncMsg().

Referenced by DtSyncPointMsg(), and set().

void DtSyncPointMsg::setFederates ( const DtFederateHandleSet set) [virtual]

Set the set of federate handles to be encoded in the message.

References handleArray(), rti1516e::insertBytes(), netSyncMsg(), numFederates(), DtNetSyncMsg::numHandles, and set().

Referenced by DtSyncPointMsg(), and set().

Set/Get synchronization message kind.

References DtNetSyncMsg::kind, and netSyncMsg().

Referenced by DtSyncPointMsg(), and set().

void DtSyncPointMsg::setSyncPointName ( char const *  name) [virtual]

Set/Get synchronization point name.

References rti1516e::insertBytes(), nameFieldSize(), namePtr(), DtNetSyncMsg::nameSize, and netSyncMsg().

Referenced by DtSyncPointMsg(), and set().

void DtSyncPointMsg::setSyncPointStatus ( DtSyncPointStatus  statusValue) [virtual]

Set/Get sync point status.

References netSyncMsg(), and DtNetSyncMsg::status.

Referenced by DtSyncPointMsg(), and set().

void DtSyncPointMsg::setTag ( char const *  tag) [virtual]

Set the set of unsuccessfully synched federate handles to be encoded in the message.

References rti1516e::insertBytes(), netSyncMsg(), numUnsuccessfulFederates(), DtNetSyncMsg::numUnsuccessfulHandles, set(), and unsuccessfulHandleArray().

Referenced by DtSyncPointMsg(), and set().

const char * DtSyncPointMsg::syncPointName ( ) const [virtual]
const char * DtSyncPointMsg::tag ( ) const [virtual]
int DtSyncPointMsg::tagFieldSize ( ) const [protected, virtual]

References netSyncMsg(), and DtNetSyncMsg::tagSize.

Referenced by namePtr(), setTag(), and tag().

char * DtSyncPointMsg::tagPtr ( ) [protected, virtual]

Returns the set of unsuccessfully synched federates encoded in the message.

The object returned is a reference to internal memory, and is only valid until the next time federates() is called.

References getUnsuccessfulFederates(), myUnsuccessfulSet, NULL, and numUnsuccessfulFederates().

DtNetU32 * DtSyncPointMsg::unsuccessfulHandleArray ( ) [protected, virtual]
int DtSyncPointMsg::unsuccessfulHandleArraySize ( ) const [protected, virtual]

Member Data Documentation

MAKRti::DtString DtSyncPointMsg::myName [protected]

Referenced by syncPointName().

Referenced by federates(), and ~DtSyncPointMsg().

char* DtSyncPointMsg::myTag [protected]

Referenced by tag(), and ~DtSyncPointMsg().

Referenced by unsuccessfulFederates().


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

Document ID: Generated on Thu Jun 14 14:15:04 EDT 2012 from SVN revision 116116
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)