MAK RTIspy API Documentation for HLA 1.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Private Member Functions
DtRtiAmbassadorBaseImplementor Class Referenceabstract

This class is a base for the protocol specific DtRtiAmbassadorImplementor class. More...

+ Collaboration diagram for DtRtiAmbassadorBaseImplementor:

Public Member Functions

virtual ~DtRtiAmbassadorBaseImplementor ()
 Destructor. More...
 
virtual void addObserver (const MAKRti::DtString &name, DtRtiAmbassadorObserver *observer)
 Add/Remove observers to the LRC's observer list. More...
 
virtual DtRtiAmbassadorObserver * removeObserver (const MAKRti::DtString &name)
 
virtual void addFedAmbWrapper (const MAKRti::DtString &name, DtFedAmbWrapper *wrapper)
 Add/Remove federate wrappers to the LRC's federate wrapper list. More...
 
virtual DtFedAmbWrapperremoveFedAmbWrapper (const MAKRti::DtString &name)
 
virtual bool enterServiceCall (const MAKRti::DtString &serviceCallName)
 Prepare for a service call Called by RTI Ambassador services to gain mutually exclusive access to RTI managers. More...
 
virtual void exitServiceCall (const MAKRti::DtString &serviceCallName)
 Finish a service call. More...
 
virtual bool isConnected () const
 Is the connection completed? More...
 
virtual DtRIDParametersparams ()
 Get the RID parameters. More...
 
virtual DtFederateMgrvalidatedFedMgr (const char *serviceCallName=nullptr)
 Get federate manager Will throw RTI Exception if not initialized Print verbose diagnostic if serviceCall name provided. More...
 
virtual DtFederateMgrnakedFedMgr ()
 Get the federate mgr Returns even when not initialized (with null) More...
 
virtual DtConnectionMgrvalidatedConnectMgr ()
 Get the connection mgr Will throw RTI Exception if not initialized. More...
 
virtual DtConnectionMgrnakedConnectMgr ()
 Get the connection mgr Returns even when not initialized (with null) More...
 
virtual DtObjectMgrobjMgr ()
 Get the object mgr If the LRC is unjoined, this will return NULL. More...
 
virtual DtInteractionMgrinterMgr ()
 Get the interaction mgr If the LRC is unjoined, this will return NULL. More...
 
virtual DtFomClassMgrfomMgr ()
 Get the fom mgr If the LRC is unjoined, this will return NULL. More...
 
virtual DtRtiAmbObserverListobservers ()
 Return the observer list. More...
 
virtual const
DtRtiAmbObserverList
observers () const
 Return the observer list. More...
 
virtual void enableLogging ()
 Enables logging if it is not already enabled Plugin Users should never need to call this. More...
 
virtual std::shared_ptr
< MAKRti::DtFilePrinter > 
logPrinter ()
 Get the printer which prints output to the log file. More...
 
unsigned long flags () const
 
virtual DtFederateMgrvalidateIsJoined (const char *serviceCallName, bool printDiagnostic=false)
 Validate that federate is joined. More...
 
virtual const DtFederateMgrvalidateIsJoined (const char *serviceCallName, bool printDiagnostic=false) const
 Validate that federate is joined. More...
 

Protected Types

enum  DtProcessingModelOverride { DtImmediateCallbacks = 0, DtEvokedCallbacks, DtDefaultModel }
 0 == Use an immediate callback processing model 1 == Use an evoked callback processing model 2 == Use default processing model More...
 

Protected Member Functions

 DtRtiAmbassadorBaseImplementor ()
 Abstract class, do not instantiate. More...
 
virtual void setupConnection (const std::vector< MAKRti::DtString > &rid, DtProcessingModelOverride processingModelOverride=DtDefaultModel)
 Establish preliminary connection configuration and infrastructure. More...
 
virtual void performParameterOverrides (DtRIDParameters &ridParams, DtProcessingModelOverride processingModelOverride) const
 Override RID parameter options. More...
 
virtual bool completeConnection (MAKRti::DtString &errorMessage)
 Complete the connection infrastructure Throws if there is a fatal failure Returns boolean: connection completed successfully? If not it is possible to try again. More...
 
virtual void clearConnection ()
 Remove the connection. More...
 
virtual void clearManagers ()
 
virtual void shutdown ()
 Prepare asynchronous connection for shutdown. More...
 
virtual bool performMulticastDiscovery ()
 Attempt to automatically detect the RTI Forwarder (or RTI Exec) Returns false if not found. More...
 
virtual void printDisabledService (const MAKRti::DtString &service)
 Print a disabled service. More...
 
virtual unsigned long incrementServiceCallCount ()
 Increment the service call count and return its value. More...
 
virtual bool tickOnce ()
 Called from tick/evokeCallback: Ticks the federate manager. More...
 
virtual void throwInternalError (const MAKRti::DtString &errorMessage) const =0
 Throw an RTI internal exception. More...
 
virtual void throwNotConnected (const MAKRti::DtString &errorMessage) const =0
 Throw an RTI not connected exception (internal for 1.3 & 1516) More...
 
virtual void throwNotJoined (const MAKRti::DtString &errorMessage) const =0
 Throw an RTI not joined exception. More...
 
virtual void attachStreams (MAKRti::DtPrinter *printer)
 
virtual void detachStreams (MAKRti::DtPrinter *printer)
 
virtual void detachAllStreams ()
 

Protected Attributes

DtRIDParametersmyParams
 The RTI initialization parameters. More...
 
DtConnectionMgrmyConnectMgr
 The connection manager. More...
 
DtFederateMgrmyFedMgr
 The federate manager. More...
 
DtRtiPluginManagermyPluginMgr
 The plugin manager. More...
 
DtRtiAmbObserverListmyObservers
 The list of RTI Ambassador observers. More...
 
DtRtiAmbObserverListmyEmptyObserverList
 The empty list. More...
 
std::shared_ptr
< DtRtiAssistantLrcClient
myAssistantClient
 The assistant client. We cache it until we're initialized. More...
 
std::shared_ptr
< MAKRti::DtFilePrinter > 
myLogPrinter
 The printer which prints output to the log file. More...
 
std::shared_ptr
< DtAssistantPrinter
myAssistantPrinter
 The printer which sends output to the assistant file. More...
 
std::shared_ptr< DtPrinterBufmyPrinterBuffer
 The printer which captures output before connecting. More...
 
std::shared_ptr< DtBufferPrintermyBufferPrinter
 
bool myCallbacksEnabled
 Indicates callbacks enabled status. More...
 
MAKRti::DtClock myClock
 Clock used for timing. More...
 
unsigned long myFlags
 
bool myUseBusyWaitForTick
 
bool myImmediateCallbackModel
 
MAKRti::DtString myErrorMessage
 

Private Member Functions

 DtRtiAmbassadorBaseImplementor (const DtRtiAmbassadorBaseImplementor &)
 Copy Constructor not implemented – Copy Not Allowed! More...
 
DtRtiAmbassadorBaseImplementoroperator= (const DtRtiAmbassadorBaseImplementor &)
 Assignment not implemented – Assignment Not Allowed! More...
 

Detailed Description

This class is a base for the protocol specific DtRtiAmbassadorImplementor class.

It performs the common initialization and processing for setting up connections and establishing the common infrastructure. The protocol specific DtRtiAmbassadorImplementor that derive from this class implement the RTIambassador services defined in the HLA specification by forwarding federate requests to the appropriate sub-managers.

Member Enumeration Documentation

0 == Use an immediate callback processing model 1 == Use an evoked callback processing model 2 == Use default processing model

Enumerator
DtImmediateCallbacks 
DtEvokedCallbacks 
DtDefaultModel 

Constructor & Destructor Documentation

DtRtiAmbassadorBaseImplementor::DtRtiAmbassadorBaseImplementor ( )
protected

Abstract class, do not instantiate.

virtual DtRtiAmbassadorBaseImplementor::~DtRtiAmbassadorBaseImplementor ( )
virtual

Destructor.

DtRtiAmbassadorBaseImplementor::DtRtiAmbassadorBaseImplementor ( const DtRtiAmbassadorBaseImplementor )
private

Copy Constructor not implemented – Copy Not Allowed!

Member Function Documentation

virtual void DtRtiAmbassadorBaseImplementor::addFedAmbWrapper ( const MAKRti::DtString &  name,
DtFedAmbWrapper wrapper 
)
virtual

Add/Remove federate wrappers to the LRC's federate wrapper list.

virtual void DtRtiAmbassadorBaseImplementor::addObserver ( const MAKRti::DtString &  name,
DtRtiAmbassadorObserver *  observer 
)
virtual

Add/Remove observers to the LRC's observer list.

virtual void DtRtiAmbassadorBaseImplementor::attachStreams ( MAKRti::DtPrinter *  printer)
protectedvirtual
virtual void DtRtiAmbassadorBaseImplementor::clearConnection ( )
protectedvirtual

Remove the connection.

virtual void DtRtiAmbassadorBaseImplementor::clearManagers ( )
protectedvirtual
virtual bool DtRtiAmbassadorBaseImplementor::completeConnection ( MAKRti::DtString &  errorMessage)
protectedvirtual

Complete the connection infrastructure Throws if there is a fatal failure Returns boolean: connection completed successfully? If not it is possible to try again.

Error message provided if recoverable failure occurs

virtual void DtRtiAmbassadorBaseImplementor::detachAllStreams ( )
protectedvirtual
virtual void DtRtiAmbassadorBaseImplementor::detachStreams ( MAKRti::DtPrinter *  printer)
protectedvirtual
virtual void DtRtiAmbassadorBaseImplementor::enableLogging ( )
virtual

Enables logging if it is not already enabled Plugin Users should never need to call this.

virtual bool DtRtiAmbassadorBaseImplementor::enterServiceCall ( const MAKRti::DtString &  serviceCallName)
virtual

Prepare for a service call Called by RTI Ambassador services to gain mutually exclusive access to RTI managers.

Also checks that connection is fully initialized (throws if not). Return true if entered with access to lock

virtual void DtRtiAmbassadorBaseImplementor::exitServiceCall ( const MAKRti::DtString &  serviceCallName)
virtual

Finish a service call.

unsigned long DtRtiAmbassadorBaseImplementor::flags ( ) const
virtual DtFomClassMgr* DtRtiAmbassadorBaseImplementor::fomMgr ( )
virtual

Get the fom mgr If the LRC is unjoined, this will return NULL.

virtual unsigned long DtRtiAmbassadorBaseImplementor::incrementServiceCallCount ( )
protectedvirtual

Increment the service call count and return its value.

Null operation if not yet connected (returns 0).

virtual DtInteractionMgr* DtRtiAmbassadorBaseImplementor::interMgr ( )
virtual

Get the interaction mgr If the LRC is unjoined, this will return NULL.

virtual bool DtRtiAmbassadorBaseImplementor::isConnected ( ) const
virtual

Is the connection completed?

virtual std::shared_ptr<MAKRti::DtFilePrinter> DtRtiAmbassadorBaseImplementor::logPrinter ( )
virtual

Get the printer which prints output to the log file.

virtual DtConnectionMgr* DtRtiAmbassadorBaseImplementor::nakedConnectMgr ( )
virtual

Get the connection mgr Returns even when not initialized (with null)

virtual DtFederateMgr* DtRtiAmbassadorBaseImplementor::nakedFedMgr ( )
virtual

Get the federate mgr Returns even when not initialized (with null)

virtual DtObjectMgr* DtRtiAmbassadorBaseImplementor::objMgr ( )
virtual

Get the object mgr If the LRC is unjoined, this will return NULL.

virtual DtRtiAmbObserverList* DtRtiAmbassadorBaseImplementor::observers ( )
virtual

Return the observer list.

virtual const DtRtiAmbObserverList* DtRtiAmbassadorBaseImplementor::observers ( ) const
virtual

Return the observer list.

DtRtiAmbassadorBaseImplementor& DtRtiAmbassadorBaseImplementor::operator= ( const DtRtiAmbassadorBaseImplementor )
private

Assignment not implemented – Assignment Not Allowed!

virtual DtRIDParameters* DtRtiAmbassadorBaseImplementor::params ( )
virtual

Get the RID parameters.

virtual bool DtRtiAmbassadorBaseImplementor::performMulticastDiscovery ( )
protectedvirtual

Attempt to automatically detect the RTI Forwarder (or RTI Exec) Returns false if not found.

virtual void DtRtiAmbassadorBaseImplementor::performParameterOverrides ( DtRIDParameters ridParams,
DtProcessingModelOverride  processingModelOverride 
) const
protectedvirtual

Override RID parameter options.

Overrides RID parameters based on connection status and other settings.

virtual void DtRtiAmbassadorBaseImplementor::printDisabledService ( const MAKRti::DtString &  service)
protectedvirtual

Print a disabled service.

virtual DtFedAmbWrapper* DtRtiAmbassadorBaseImplementor::removeFedAmbWrapper ( const MAKRti::DtString &  name)
virtual
virtual DtRtiAmbassadorObserver* DtRtiAmbassadorBaseImplementor::removeObserver ( const MAKRti::DtString &  name)
virtual
virtual void DtRtiAmbassadorBaseImplementor::setupConnection ( const std::vector< MAKRti::DtString > &  rid,
DtProcessingModelOverride  processingModelOverride = DtDefaultModel 
)
protectedvirtual

Establish preliminary connection configuration and infrastructure.

virtual void DtRtiAmbassadorBaseImplementor::shutdown ( )
protectedvirtual

Prepare asynchronous connection for shutdown.

virtual void DtRtiAmbassadorBaseImplementor::throwInternalError ( const MAKRti::DtString &  errorMessage) const
protectedpure virtual

Throw an RTI internal exception.

virtual void DtRtiAmbassadorBaseImplementor::throwNotConnected ( const MAKRti::DtString &  errorMessage) const
protectedpure virtual

Throw an RTI not connected exception (internal for 1.3 & 1516)

virtual void DtRtiAmbassadorBaseImplementor::throwNotJoined ( const MAKRti::DtString &  errorMessage) const
protectedpure virtual

Throw an RTI not joined exception.

virtual bool DtRtiAmbassadorBaseImplementor::tickOnce ( )
protectedvirtual

Called from tick/evokeCallback: Ticks the federate manager.

virtual DtConnectionMgr* DtRtiAmbassadorBaseImplementor::validatedConnectMgr ( )
virtual

Get the connection mgr Will throw RTI Exception if not initialized.

virtual DtFederateMgr* DtRtiAmbassadorBaseImplementor::validatedFedMgr ( const char *  serviceCallName = nullptr)
virtual

Get federate manager Will throw RTI Exception if not initialized Print verbose diagnostic if serviceCall name provided.

virtual DtFederateMgr* DtRtiAmbassadorBaseImplementor::validateIsJoined ( const char *  serviceCallName,
bool  printDiagnostic = false 
)
virtual

Validate that federate is joined.

If not valid, throw not joined exception. Print service call diagnostic if indicated. Return the federate manager if everything is OK

virtual const DtFederateMgr* DtRtiAmbassadorBaseImplementor::validateIsJoined ( const char *  serviceCallName,
bool  printDiagnostic = false 
) const
virtual

Validate that federate is joined.

If not valid, throw not joined exception. Print service call diagnostic if indicated. Return the federate manager if everything is OK

Member Data Documentation

std::shared_ptr<DtRtiAssistantLrcClient> DtRtiAmbassadorBaseImplementor::myAssistantClient
protected

The assistant client. We cache it until we're initialized.

std::shared_ptr<DtAssistantPrinter> DtRtiAmbassadorBaseImplementor::myAssistantPrinter
protected

The printer which sends output to the assistant file.

std::shared_ptr<DtBufferPrinter> DtRtiAmbassadorBaseImplementor::myBufferPrinter
protected
bool DtRtiAmbassadorBaseImplementor::myCallbacksEnabled
protected

Indicates callbacks enabled status.

MAKRti::DtClock DtRtiAmbassadorBaseImplementor::myClock
protected

Clock used for timing.

DtConnectionMgr* DtRtiAmbassadorBaseImplementor::myConnectMgr
protected

The connection manager.

DtRtiAmbObserverList* DtRtiAmbassadorBaseImplementor::myEmptyObserverList
protected

The empty list.

MAKRti::DtString DtRtiAmbassadorBaseImplementor::myErrorMessage
protected
DtFederateMgr* DtRtiAmbassadorBaseImplementor::myFedMgr
protected

The federate manager.

unsigned long DtRtiAmbassadorBaseImplementor::myFlags
protected
bool DtRtiAmbassadorBaseImplementor::myImmediateCallbackModel
protected
std::shared_ptr<MAKRti::DtFilePrinter> DtRtiAmbassadorBaseImplementor::myLogPrinter
protected

The printer which prints output to the log file.

DtRtiAmbObserverList* DtRtiAmbassadorBaseImplementor::myObservers
protected

The list of RTI Ambassador observers.

DtRIDParameters* DtRtiAmbassadorBaseImplementor::myParams
protected

The RTI initialization parameters.

DtRtiPluginManager* DtRtiAmbassadorBaseImplementor::myPluginMgr
protected

The plugin manager.

std::shared_ptr<DtPrinterBuf> DtRtiAmbassadorBaseImplementor::myPrinterBuffer
protected

The printer which captures output before connecting.

bool DtRtiAmbassadorBaseImplementor::myUseBusyWaitForTick
protected

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

Document ID: Generated on Sun Jul 20 16:15:30 EDT 2025 from SVN revision 277985
Copyright © 2005-2025 MAK Technologies Inc. All Rights Reserved (www.mak.com)