org.npsnet.xrti
Class FederationExecutionAmbassador

java.lang.Object
  extended byorg.npsnet.xrti.XRTIAmbassador
      extended byorg.npsnet.xrti.FederationExecutionAmbassador
All Implemented Interfaces:
BootstrapInteractionListener, ManagementInteractionListener, RTIambassador, RTIambassadorEx

public class FederationExecutionAmbassador
extends XRTIAmbassador

A special version of the XRTIAmbassador that the XRTIExecutive uses to address federation executions.

Author:
Andrzej Kapolka, Stanislav Kozina

Field Summary
private static java.lang.String ACCURACY
          The accuracy attribute.
private static java.lang.String ALTERNATIVE
          The alternative tag.
private static java.lang.String ARRAY_DATA
          The array data tag.
private  java.util.HashMap arrayDataTypeNameProxyMap
          Maps array data type names to their proxies.
private static java.lang.String ATTRIBUTE
          The attribute tag.
private static java.lang.String BASIC_DATA
          The basic data tag.
private  java.util.HashMap basicRepresentationNameProxyMap
          Maps basic representation names to their proxies.
private static java.lang.String CAPABILITY
          The capability attribute.
private static java.lang.String CARDINALITY
          The cardinality attribute.
private static java.lang.String DATA_TYPE
          The data type attribute.
private static java.lang.String DESCRIPTION
          The description attribute.
private static java.lang.String DIMENSION
          The dimension tag.
private  java.util.HashMap dimensionNameProxyMap
          Maps dimension names to their proxies.
private static java.lang.String DIMENSIONS
          The dimensions attribute.
private static java.lang.String DISCRIMINANT
          The discriminant attribute.
private static java.lang.String ENCODING
          The encoding attribute.
private static java.lang.String ENDIAN
          The endian attribute.
private static java.lang.String ENUMERATED_DATA
          The enumerated data tag.
private  java.util.HashMap enumeratedDataTypeNameProxyMap
          Maps enumerated data type names to their proxies.
private static java.lang.String ENUMERATOR
          The enumerator tag.
private  HLAfederationExecutionProxy executionProxy
          The federation execution proxy in the meta-federation.
private  XRTIExecutive executive
          The owning XRTIExecutive.
private  java.util.Vector executiveClientAmbassadors
          The list of registered executive client ambassadors.
private static java.lang.String FIELD
          The field tag.
private static java.lang.String FIXED_RECORD_DATA
          The fixed record data tag.
private  java.util.HashMap fixedRecordDataTypeNameProxyMap
          Maps fixed record data type names to their proxies.
private static java.lang.String INTERACTION_CLASS
          The interaction class tag.
private  java.util.HashMap interactionClassNameProxyMap
          Maps interaction class names to their proxies.
private static java.lang.String INTERPRETATION
          The interpretation attribute.
private static java.lang.String LABEL
          The label attribute.
private static java.lang.String NAME
          The name attribute.
private static java.lang.String NORMALIZATION
          The normalization attribute.
private static java.lang.String OBJECT_CLASS
          The object class tag.
private  java.util.HashMap objectClassNameProxyMap
          Maps object class names to their proxies.
private  java.util.HashMap objectInstanceHandleOwnerMap
          Maps object instance handles to the executive client ambassadors of their owners.
private static java.lang.String ORDER
          The order attribute.
private static java.lang.String OWNERSHIP
          The ownership attribute.
private static java.lang.String PARAMETER
          The parameter tag.
private static java.lang.String PARENTS
          The parents attribute.
private static java.lang.String REPRESENTATION
          The representation attribute.
private static java.lang.String RESOLUTION
          The resolution attribute.
private static java.lang.String SEMANTICS
          The semantics attribute.
private static java.lang.String SHARING
          The sharing attribute.
private static java.lang.String SIMPLE_DATA
          The simple data tag.
private  java.util.HashMap simpleDataTypeNameProxyMap
          Maps simple data type names to their proxies.
private static java.lang.String SIZE
          The size attribute.
private static java.lang.String SYNCHRONIZATION
          The synchronization tag.
private  java.util.HashMap synchronizationNameProxyMap
          Maps synchronization names to their proxies.
private  java.util.Map synchronizationPointLabelMap
          Maps synchronization point labels to their instances.
private static java.lang.String TRANSPORTATION
          The transportation tag.
private  java.util.HashMap transportationNameProxyMap
          Maps transportation names to their proxies.
private static java.lang.String UNITS
          The units attribute.
private static java.lang.String UPDATE_CONDITION
          The update condition attribute.
private static java.lang.String UPDATE_TYPE
          The update type attribute.
private static java.lang.String UPPER_BOUND
          The upper bound attribute.
private static java.lang.String VALUE
          The value attribute.
private static java.lang.String VALUES
          The values attribute.
private static java.lang.String VARIANT_RECORD_DATA
          The variant record data tag.
private  java.util.HashMap variantRecordDataTypeNameProxyMap
          Maps variant record data type names to their proxies.
 
Fields inherited from class org.npsnet.xrti.XRTIAmbassador
asynchronousDeliveryEnabled, bootstrapProxyAmbassador, descriptorManager, handleCounter, HLA_META_FEDERATION_EXECUTION, channel, inTimeAdvancingState, joinedFederationExecutionHandle, joinedFederationExecutionName, logicalTime, logicalTimeFactory, logicalTimeIntervalFactory, lookahead, managementProxyAmbassador, metaFederationProxyAmbassador, proxyAmbassador, reflectionProxyAmbassador, requestedLogicalTime, timeConstrainedEnabled, timeRegulationEnabled
 
Constructor Summary
protected FederationExecutionAmbassador(XRTIExecutive pExecutive, HLAfederationExecutionProxy pExecutionProxy, java.lang.String pExecutionName, long pExecutionHandle)
          Constructor.
 
Method Summary
protected  boolean allZeroLookaheadFederatesRestricted(ExecutiveClientAmbassador eca)
          Returns true if all zero lookahead federates in current federation execution are subject of zero lookahead restriction, false otherwise.
private  void computeAllGaltValues(ExecutiveClientAmbassador eca)
          Performs computation of the Greatest Available Logical Time (GALT) for all federates in current federation execution.
 void createReflectionObjects(org.w3c.dom.Document fdd)
          Creates reflection objects corresponding to the elements of the specifed federation description document.
 void deleteObjectInstance(ExecutiveClientAmbassador eca, ObjectInstanceHandle oih, byte[] userSuppliedTag)
          Deletes the object instance with the specified handle.
 void deregisterExecutiveClientAmbassador(ExecutiveClientAmbassador eca)
          Removes an executive client ambassador from this federation execution.
 HLAfederationExecutionProxy getExecutionProxy()
          Returns a reference to the federation execution proxy in the meta-federation.
protected  java.util.Vector getExecutiveClientAmbassadors()
          Returns the list of registered executive client ambassadors.
protected  void handleTimeRequest(ExecutiveClientAmbassador eca)
          Handles time request received from a federate.
 boolean hasExecutiveClientAmbassadors()
          Checks whether or not this federation execution has any executive client ambassadors registered.
 void publishInteractionClass(InteractionClassHandle theInteraction)
          Publishes the specified interaction class.
 void publishObjectClassAttributes(ObjectClassHandle theClass, AttributeHandleSet attributeList)
          Publishes the specified object class attributes.
 void registerExecutiveClientAmbassador(ExecutiveClientAmbassador eca)
          Adds an executive client ambassador to this federation execution.
 boolean registerFederationSynchronizationPoint(ExecutiveClientAmbassador eca, java.lang.String synchronizationPointLabel, byte[] userSuppliedTag, FederateHandleSet synchronizationSet)
          Registers a federation synchronization point.
 void registerObjectInstance(ExecutiveClientAmbassador eca, ObjectInstanceDescriptor oid, byte[] userSuppliedTag)
          Registers an object instance created by a federate.
 void registerObjectInstances(ExecutiveClientAmbassador eca, ObjectClassHandle och)
          Registers all instances of a particular class.
 void requestAttributeValueUpdate(ObjectInstanceHandle theObject, AttributeHandleSet theAttributes, byte[] userSuppliedTag)
          Requests an attribute value update.
private  void sendAllPossibleTimeAdvanceGrants(ExecutiveClientAmbassador eca)
          Sends all possible timeAdvanceGrant callbacks to all federates in current federation execution.
 void sendInteraction(ExecutiveClientAmbassador eca, InteractionClassHandle theInteraction, ParameterHandleValueMap theParameters, byte[] userSuppliedTag, TransportationType theTransport, OrderType sentOrdering, LogicalTime theTime)
          Sends an interaction received from a federate.
 void sendInteraction(InteractionClassHandle theInteraction, ParameterHandleValueMap theParameters, byte[] userSuppliedTag)
          Sends an interaction.
 void subscribeInteractionClass(InteractionClassHandle theClass)
          Subscribes to the specified interaction class.
 void subscribeObjectClassAttributes(ObjectClassHandle theClass, AttributeHandleSet attributeList)
          Subscribes to a set of object class attributes.
 void synchronizationPointAchieved(ExecutiveClientAmbassador eca, java.lang.String synchronizationPointLabel)
          Notifies the run-time infrastructure that a synchronization point has been achieved.
 java.lang.String toString()
          Returns a string representation of the FederationExecutionAmbassador.
 void updateAttributeValuesBestEffort(ExecutiveClientAmbassador eca, XRTIObjectInstanceHandle xoih, HLAattributeHandleValuePair[] attributeHandleValuePairList, byte[] userSuppliedTag)
          Updates a set of attributes with best-effort transportation.
 void updateAttributeValuesReliable(ExecutiveClientAmbassador eca, XRTIObjectInstanceHandle xoih, HLAattributeHandleValuePair[] attributeHandleValuePairList, byte[] userSuppliedTag)
          Updates a set of attributes with reliable transportation.
 
Methods inherited from class org.npsnet.xrti.XRTIAmbassador
associateRegionsForUpdates, attributeOwnershipAcquisition, attributeOwnershipAcquisitionIfAvailable, attributeOwnershipDivestitureIfWanted, cancelAttributeOwnershipAcquisition, cancelNegotiatedAttributeOwnershipDivestiture, commitRegionModifications, confirmDivestiture, createDescriptorManagerAndProxyAmbassadors, createFederationExecution, createMessageThreads, createRegion, debug, decodeLogicalTime, deleteObjectInstance, deleteObjectInstance, deleteRegion, destroyFederationExecution, disableAsynchronousDelivery, disableAttributeRelevanceAdvisorySwitch, disableAttributeScopeAdvisorySwitch, disableCallbacks, disableInteractionRelevanceAdvisorySwitch, disableObjectClassRelevanceAdvisorySwitch, disableTimeConstrained, disableTimeRegulation, enableAsynchronousDelivery, enableAttributeRelevanceAdvisorySwitch, enableAttributeScopeAdvisorySwitch, enableCallbacks, enableInteractionRelevanceAdvisorySwitch, enableObjectClassRelevanceAdvisorySwitch, enableTimeConstrained, enableTimeRegulation, evokeCallback, evokeMultipleCallbacks, federateRestoreComplete, federateRestoreNotComplete, federateSaveBegun, federateSaveComplete, federateSaveNotComplete, finalizeRTI, flushQueueRequest, getAttributeHandle, getAttributeHandleFactory, getAttributeHandleSetFactory, getAttributeHandleValueMapFactory, getAttributeName, getAttributeSetRegionSetPairListFactory, getAvailableDimensionsForClassAttribute, getAvailableDimensionsForInteractionClass, getDimensionHandle, getDimensionHandleFactory, getDimensionHandleSet, getDimensionHandleSetFactory, getDimensionName, getDimensionUpperBound, getFederateHandleFactory, getFederateHandleSetFactory, getHLAversion, getInteractionClassHandle, getInteractionClassHandleFactory, getInteractionClassName, getKnownObjectClassHandle, getObjectClassHandle, getObjectClassHandleFactory, getObjectClassName, getObjectInstanceHandle, getObjectInstanceHandleFactory, getObjectInstanceName, getOrderName, getOrderType, getParameterHandle, getParameterHandleFactory, getParameterHandleValueMapFactory, getParameterName, getRangeBounds, getRegionHandleSetFactory, getTransportationName, getTransportationType, changeAttributeOrderType, changeAttributeTransportationType, changeInteractionOrderType, changeInteractionTransportationType, initializeRTI, isAttributeOwnedByFederate, isZeroLookaheadRestricted, joinFederationExecution, localDeleteObjectInstance, mergeFDD, modifyLookahead, negotiatedAttributeOwnershipDivestiture, nextMessageRequest, nextMessageRequestAvailable, normalizeFederateHandle, normalizeServiceGroup, proxyAmbassador_receiveInteraction, queryAttributeOwnership, queryFederationRestoreStatus, queryFederationSaveStatus, queryGALT, queryLITS, queryLogicalTime, queryLookahead, receiveHLAannounceSynchronizationPoint, receiveHLAcontinue, receiveHLAdeleteObjectInstance, receiveHLAdisableAsynchronousDelivery, receiveHLAdisableTimeConstrained, receiveHLAdisableTimeRegulation, receiveHLAenableAsynchronousDelivery, receiveHLAenableTimeConstrained, receiveHLAenableTimeRegulation, receiveHLAfederateRestoreComplete, receiveHLAfederateSaveBegun, receiveHLAfederateSaveComplete, receiveHLAfederationSynchronized, receiveHLAflushQueueRequest, receiveHLAchangeAttributeOrderType, receiveHLAchangeAttributeTransportationType, receiveHLAchangeInteractionOrderType, receiveHLAchangeInteractionTransportationType, receiveHLAinteractionFragment, receiveHLAlocalDeleteObjectInstance, receiveHLAmodifyAttributeState, receiveHLAmodifyLookahead, receiveHLAnextMessageRequest, receiveHLAnextMessageRequestAvailable, receiveHLApublishInteractionClass, receiveHLApublishObjectClassAttributes, receiveHLAregisterFederationSynchronizationPoint, receiveHLAregisterObjectInstance, receiveHLAreportException, receiveHLAreportHandles, receiveHLAreportInteractionPublication, receiveHLAreportInteractionsReceived, receiveHLAreportInteractionsSent, receiveHLAreportInteractionSubscription, receiveHLAreportMOMexception, receiveHLAreportObjectClassPublication, receiveHLAreportObjectClassSubscription, receiveHLAreportObjectInstanceInformation, receiveHLAreportObjectInstancesReflected, receiveHLAreportObjectInstancesThatCanBeDeleted, receiveHLAreportObjectInstancesUpdated, receiveHLAreportReflectionsReceived, receiveHLAreportServiceInvocation, receiveHLAreportSynchronizationPoints, receiveHLAreportSynchronizationPointStatus, receiveHLAreportUpdatesSent, receiveHLArequestAttributeValueUpdate, receiveHLArequestHandles, receiveHLArequestInteractionsReceived, receiveHLArequestInteractionsSent, receiveHLArequestObjectInstanceInformation, receiveHLArequestObjectInstancesReflected, receiveHLArequestObjectInstancesThatCanBeDeleted, receiveHLArequestObjectInstancesUpdated, receiveHLArequestPublications, receiveHLArequestReflectionsReceived, receiveHLArequestSubscriptions, receiveHLArequestSynchronizationPoints, receiveHLArequestSynchronizationPointStatus, receiveHLArequestUpdatesSent, receiveHLAresignFederationExecution, receiveHLAresultBoolean, receiveHLAsetExceptionReporting, receiveHLAsetServiceReporting, receiveHLAsetSwitches, receiveHLAsetTiming, receiveHLAsubscribeInteractionClass, receiveHLAsubscribeObjectClassAttributes, receiveHLAsynchronizationPointAchieved, receiveHLAsynchronizationPointRegistrationFailed, receiveHLAsynchronizationPointRegistrationSucceeded, receiveHLAtimeAdvanceGrant, receiveHLAtimeAdvanceRequest, receiveHLAtimeAdvanceRequestAvailable, receiveHLAtimeConstrainedEnabled, receiveHLAtimeRegulationEnabled, receiveHLAunconditionalAttributeOwnershipDivestiture, receiveHLAunpublishInteractionClass, receiveHLAunpublishObjectClassAttributes, receiveHLAunsubscribeInteractionClass, receiveHLAunsubscribeObjectClassAttributes, receiveHLAupdateAttributeValuesBestEffort, receiveHLAupdateAttributeValuesReliable, registerFederationSynchronizationPoint, registerFederationSynchronizationPoint, registerObjectInstance, registerObjectInstance, registerObjectInstanceWithRegions, registerObjectInstanceWithRegions, requestAttributeValueUpdate, requestAttributeValueUpdateWithRegions, requestFederationRestore, requestFederationSave, requestFederationSave, reserveObjectInstanceName, resignFederationExecution, retract, sendInteraction, sendInteractionBestEffort, sendInteractionReliable, sendInteractionWithRegions, sendInteractionWithRegions, setRangeBounds, subscribeInteractionClassPassively, subscribeInteractionClassPassivelyWithRegions, subscribeInteractionClassWithRegions, subscribeObjectClassAttributesPassively, subscribeObjectClassAttributesPassivelyWithRegions, subscribeObjectClassAttributesWithRegions, synchronizationPointAchieved, timeAdvanceRequest, timeAdvanceRequestAvailable, turnZeroLookaheadRestrictionOffIfPossible, turnZeroLookaheadRestrictionOn, unassociateRegionsForUpdates, unconditionalAttributeOwnershipDivestiture, unpublishInteractionClass, unpublishObjectClass, unpublishObjectClassAttributes, unsubscribeInteractionClass, unsubscribeInteractionClassWithRegions, unsubscribeObjectClass, unsubscribeObjectClassAttributes, unsubscribeObjectClassAttributesWithRegions, updateAttributeValues, updateAttributeValues, verifyFederateIsExecutionMember, verifyFederateIsNotInTimeAdvancingState, verifyLookaheadIsValid, verifyNoRestoreInProgress, verifyNoSaveInProgress, verifyRequestedTimeIsValid, verifyRequestForTimeConstrainedIsNotPending, verifyRequestForTimeRegulationIsNotPending, verifyTimeStampIsValid
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

OBJECT_CLASS

private static final java.lang.String OBJECT_CLASS
The object class tag.

See Also:
Constant Field Values

ATTRIBUTE

private static final java.lang.String ATTRIBUTE
The attribute tag.

See Also:
Constant Field Values

INTERACTION_CLASS

private static final java.lang.String INTERACTION_CLASS
The interaction class tag.

See Also:
Constant Field Values

PARAMETER

private static final java.lang.String PARAMETER
The parameter tag.

See Also:
Constant Field Values

DIMENSION

private static final java.lang.String DIMENSION
The dimension tag.

See Also:
Constant Field Values

SYNCHRONIZATION

private static final java.lang.String SYNCHRONIZATION
The synchronization tag.

See Also:
Constant Field Values

TRANSPORTATION

private static final java.lang.String TRANSPORTATION
The transportation tag.

See Also:
Constant Field Values

BASIC_DATA

private static final java.lang.String BASIC_DATA
The basic data tag.

See Also:
Constant Field Values

SIMPLE_DATA

private static final java.lang.String SIMPLE_DATA
The simple data tag.

See Also:
Constant Field Values

ENUMERATED_DATA

private static final java.lang.String ENUMERATED_DATA
The enumerated data tag.

See Also:
Constant Field Values

ENUMERATOR

private static final java.lang.String ENUMERATOR
The enumerator tag.

See Also:
Constant Field Values

ARRAY_DATA

private static final java.lang.String ARRAY_DATA
The array data tag.

See Also:
Constant Field Values

FIXED_RECORD_DATA

private static final java.lang.String FIXED_RECORD_DATA
The fixed record data tag.

See Also:
Constant Field Values

FIELD

private static final java.lang.String FIELD
The field tag.

See Also:
Constant Field Values

VARIANT_RECORD_DATA

private static final java.lang.String VARIANT_RECORD_DATA
The variant record data tag.

See Also:
Constant Field Values

ALTERNATIVE

private static final java.lang.String ALTERNATIVE
The alternative tag.

See Also:
Constant Field Values

NAME

private static final java.lang.String NAME
The name attribute.

See Also:
Constant Field Values

PARENTS

private static final java.lang.String PARENTS
The parents attribute.

See Also:
Constant Field Values

SHARING

private static final java.lang.String SHARING
The sharing attribute.

See Also:
Constant Field Values

SEMANTICS

private static final java.lang.String SEMANTICS
The semantics attribute.

See Also:
Constant Field Values

DATA_TYPE

private static final java.lang.String DATA_TYPE
The data type attribute.

See Also:
Constant Field Values

UPDATE_TYPE

private static final java.lang.String UPDATE_TYPE
The update type attribute.

See Also:
Constant Field Values

UPDATE_CONDITION

private static final java.lang.String UPDATE_CONDITION
The update condition attribute.

See Also:
Constant Field Values

OWNERSHIP

private static final java.lang.String OWNERSHIP
The ownership attribute.

See Also:
Constant Field Values

DIMENSIONS

private static final java.lang.String DIMENSIONS
The dimensions attribute.

See Also:
Constant Field Values

ORDER

private static final java.lang.String ORDER
The order attribute.

See Also:
Constant Field Values

UPPER_BOUND

private static final java.lang.String UPPER_BOUND
The upper bound attribute.

See Also:
Constant Field Values

NORMALIZATION

private static final java.lang.String NORMALIZATION
The normalization attribute.

See Also:
Constant Field Values

VALUE

private static final java.lang.String VALUE
The value attribute.

See Also:
Constant Field Values

LABEL

private static final java.lang.String LABEL
The label attribute.

See Also:
Constant Field Values

CAPABILITY

private static final java.lang.String CAPABILITY
The capability attribute.

See Also:
Constant Field Values

DESCRIPTION

private static final java.lang.String DESCRIPTION
The description attribute.

See Also:
Constant Field Values

SIZE

private static final java.lang.String SIZE
The size attribute.

See Also:
Constant Field Values

INTERPRETATION

private static final java.lang.String INTERPRETATION
The interpretation attribute.

See Also:
Constant Field Values

ENDIAN

private static final java.lang.String ENDIAN
The endian attribute.

See Also:
Constant Field Values

ENCODING

private static final java.lang.String ENCODING
The encoding attribute.

See Also:
Constant Field Values

REPRESENTATION

private static final java.lang.String REPRESENTATION
The representation attribute.

See Also:
Constant Field Values

UNITS

private static final java.lang.String UNITS
The units attribute.

See Also:
Constant Field Values

RESOLUTION

private static final java.lang.String RESOLUTION
The resolution attribute.

See Also:
Constant Field Values

ACCURACY

private static final java.lang.String ACCURACY
The accuracy attribute.

See Also:
Constant Field Values

VALUES

private static final java.lang.String VALUES
The values attribute.

See Also:
Constant Field Values

CARDINALITY

private static final java.lang.String CARDINALITY
The cardinality attribute.

See Also:
Constant Field Values

DISCRIMINANT

private static final java.lang.String DISCRIMINANT
The discriminant attribute.

See Also:
Constant Field Values

executive

private XRTIExecutive executive
The owning XRTIExecutive.


executionProxy

private HLAfederationExecutionProxy executionProxy
The federation execution proxy in the meta-federation.


executiveClientAmbassadors

private java.util.Vector executiveClientAmbassadors
The list of registered executive client ambassadors.


objectInstanceHandleOwnerMap

private java.util.HashMap objectInstanceHandleOwnerMap
Maps object instance handles to the executive client ambassadors of their owners.


objectClassNameProxyMap

private java.util.HashMap objectClassNameProxyMap
Maps object class names to their proxies.


interactionClassNameProxyMap

private java.util.HashMap interactionClassNameProxyMap
Maps interaction class names to their proxies.


dimensionNameProxyMap

private java.util.HashMap dimensionNameProxyMap
Maps dimension names to their proxies.


synchronizationNameProxyMap

private java.util.HashMap synchronizationNameProxyMap
Maps synchronization names to their proxies.


transportationNameProxyMap

private java.util.HashMap transportationNameProxyMap
Maps transportation names to their proxies.


basicRepresentationNameProxyMap

private java.util.HashMap basicRepresentationNameProxyMap
Maps basic representation names to their proxies.


simpleDataTypeNameProxyMap

private java.util.HashMap simpleDataTypeNameProxyMap
Maps simple data type names to their proxies.


enumeratedDataTypeNameProxyMap

private java.util.HashMap enumeratedDataTypeNameProxyMap
Maps enumerated data type names to their proxies.


arrayDataTypeNameProxyMap

private java.util.HashMap arrayDataTypeNameProxyMap
Maps array data type names to their proxies.


fixedRecordDataTypeNameProxyMap

private java.util.HashMap fixedRecordDataTypeNameProxyMap
Maps fixed record data type names to their proxies.


variantRecordDataTypeNameProxyMap

private java.util.HashMap variantRecordDataTypeNameProxyMap
Maps variant record data type names to their proxies.


synchronizationPointLabelMap

private java.util.Map synchronizationPointLabelMap
Maps synchronization point labels to their instances.

Constructor Detail

FederationExecutionAmbassador

protected FederationExecutionAmbassador(XRTIExecutive pExecutive,
                                        HLAfederationExecutionProxy pExecutionProxy,
                                        java.lang.String pExecutionName,
                                        long pExecutionHandle)
Constructor.

Parameters:
pExecutive - the owning XRTIExecutive
pExecutionProxy - the federation execution proxy in the meta-federation (or null for none)
pExecutionName - the name of the federation execution
pExecutionHandle - the handle of the federation execution
Method Detail

getExecutionProxy

public HLAfederationExecutionProxy getExecutionProxy()
Returns a reference to the federation execution proxy in the meta-federation.

Returns:
a reference to the federation execution proxy, or null for none

registerExecutiveClientAmbassador

public void registerExecutiveClientAmbassador(ExecutiveClientAmbassador eca)
Adds an executive client ambassador to this federation execution.

Parameters:
eca - the executive client ambassador to register

registerObjectInstances

public void registerObjectInstances(ExecutiveClientAmbassador eca,
                                    ObjectClassHandle och)
Registers all instances of a particular class.

Parameters:
eca - the executive client ambassador to register the instances with
och - the handle of the class of objects to register

deregisterExecutiveClientAmbassador

public void deregisterExecutiveClientAmbassador(ExecutiveClientAmbassador eca)
Removes an executive client ambassador from this federation execution.

Parameters:
eca - the executive client ambassador to deregister

hasExecutiveClientAmbassadors

public boolean hasExecutiveClientAmbassadors()
Checks whether or not this federation execution has any executive client ambassadors registered.

Returns:
true if there are executive client ambassadors registered, false otherwise

createReflectionObjects

public void createReflectionObjects(org.w3c.dom.Document fdd)
                             throws RTIexception
Creates reflection objects corresponding to the elements of the specifed federation description document.

Parameters:
fdd - the federation description document to read
Throws:
RTIexception

registerObjectInstance

public void registerObjectInstance(ExecutiveClientAmbassador eca,
                                   ObjectInstanceDescriptor oid,
                                   byte[] userSuppliedTag)
Registers an object instance created by a federate.

Parameters:
eca - the executive client ambassador of the creating federate
oid - the object instance descriptor describing the object
userSuppliedTag - the user-supplied tag associated with the event

deleteObjectInstance

public void deleteObjectInstance(ExecutiveClientAmbassador eca,
                                 ObjectInstanceHandle oih,
                                 byte[] userSuppliedTag)
Deletes the object instance with the specified handle.

Parameters:
eca - the executive client ambassador of the deleting federate
oih - the object instance handle
userSuppliedTag - the user-supplied tag associated with the event

updateAttributeValuesBestEffort

public void updateAttributeValuesBestEffort(ExecutiveClientAmbassador eca,
                                            XRTIObjectInstanceHandle xoih,
                                            HLAattributeHandleValuePair[] attributeHandleValuePairList,
                                            byte[] userSuppliedTag)
Updates a set of attributes with best-effort transportation.

Parameters:
eca - the executive client ambassador of the sending federate
xoih - the object instance handle of the object being updated
attributeHandleValuePairList - the attribute handle/value pairs
userSuppliedTag - the user-supplied tag associated with the event

updateAttributeValuesReliable

public void updateAttributeValuesReliable(ExecutiveClientAmbassador eca,
                                          XRTIObjectInstanceHandle xoih,
                                          HLAattributeHandleValuePair[] attributeHandleValuePairList,
                                          byte[] userSuppliedTag)
Updates a set of attributes with reliable transportation.

Parameters:
eca - the executive client ambassador of the sending federate
xoih - the object instance handle of the object being updated
attributeHandleValuePairList - the attribute handle/value pairs
userSuppliedTag - the user-supplied tag associated with the event

publishObjectClassAttributes

public void publishObjectClassAttributes(ObjectClassHandle theClass,
                                         AttributeHandleSet attributeList)
                                  throws ObjectClassNotDefined,
                                         AttributeNotDefined,
                                         FederateNotExecutionMember,
                                         SaveInProgress,
                                         RestoreInProgress,
                                         RTIinternalError
Publishes the specified object class attributes.

Specified by:
publishObjectClassAttributes in interface RTIambassador
Overrides:
publishObjectClassAttributes in class XRTIAmbassador
Parameters:
theClass - the object class associated with the attributes to be published
attributeList - the list of attributes to publish
Throws:
ObjectClassNotDefined - if the specified object class is not defined
AttributeNotDefined - if one of the specified attributes is not defined
FederateNotExecutionMember - if the federate is not a member of an execution
SaveInProgress - if a save operation is in progress
RestoreInProgress - if a restore operation is in progress
RTIinternalError - if an internal error occurred in the run-time infrastructure

publishInteractionClass

public void publishInteractionClass(InteractionClassHandle theInteraction)
                             throws InteractionClassNotDefined,
                                    FederateNotExecutionMember,
                                    SaveInProgress,
                                    RestoreInProgress,
                                    RTIinternalError
Publishes the specified interaction class.

Specified by:
publishInteractionClass in interface RTIambassador
Overrides:
publishInteractionClass in class XRTIAmbassador
Parameters:
theInteraction - the interaction class to publish
Throws:
InteractionClassNotDefined - if the specified interaction class is not defined
FederateNotExecutionMember - if the federate is not a member of an execution
SaveInProgress - if a save operation is in progress
RestoreInProgress - if a restore operation is in progress
RTIinternalError - if an internal error occurred in the run-time infrastructure

subscribeObjectClassAttributes

public void subscribeObjectClassAttributes(ObjectClassHandle theClass,
                                           AttributeHandleSet attributeList)
                                    throws ObjectClassNotDefined,
                                           AttributeNotDefined,
                                           FederateNotExecutionMember,
                                           SaveInProgress,
                                           RestoreInProgress,
                                           RTIinternalError
Subscribes to a set of object class attributes.

Specified by:
subscribeObjectClassAttributes in interface RTIambassador
Overrides:
subscribeObjectClassAttributes in class XRTIAmbassador
Parameters:
theClass - the object class associated with the attributes to subscribe to
attributeList - the set of attributes to subscribe to
Throws:
ObjectClassNotDefined - if the specified object class is not defined
AttributeNotDefined - if one of the specified attributes is not defined
FederateNotExecutionMember - if the federate is not a member of an execution
SaveInProgress - if a save operation is in progress
RestoreInProgress - if a restore operation is in progress
RTIinternalError - if an internal error occurred in the run-time infrastructure

subscribeInteractionClass

public void subscribeInteractionClass(InteractionClassHandle theClass)
                               throws InteractionClassNotDefined,
                                      FederateServiceInvocationsAreBeingReportedViaMOM,
                                      FederateNotExecutionMember,
                                      SaveInProgress,
                                      RestoreInProgress,
                                      RTIinternalError
Subscribes to the specified interaction class.

Specified by:
subscribeInteractionClass in interface RTIambassador
Overrides:
subscribeInteractionClass in class XRTIAmbassador
Parameters:
theClass - the interaction class to subscribe to
Throws:
InteractionClassNotDefined - if the interaction class is not defined
FederateServiceInvocationsAreBeingReportedViaMOM - if federate service invocations are being reported via the management object model
FederateNotExecutionMember - if the federate is not a member of an execution
SaveInProgress - if a save operation is in progress
RestoreInProgress - if a restore operation is in progress
RTIinternalError - if an internal error occurred in the run-time infrastructure

sendInteraction

public void sendInteraction(InteractionClassHandle theInteraction,
                            ParameterHandleValueMap theParameters,
                            byte[] userSuppliedTag)
                     throws InteractionClassNotPublished,
                            InteractionClassNotDefined,
                            InteractionParameterNotDefined,
                            FederateNotExecutionMember,
                            SaveInProgress,
                            RestoreInProgress,
                            RTIinternalError
Sends an interaction.

Specified by:
sendInteraction in interface RTIambassador
Overrides:
sendInteraction in class XRTIAmbassador
Parameters:
theInteraction - the class of interaction to send
theParameters - the parameters of the interaction
userSuppliedTag - a user-supplied tag to associate with the interaction
Throws:
InteractionClassNotPublished - if the interaction class is not published
InteractionClassNotDefined - if the interaction class is undefined
InteractionParameterNotDefined - if one of the parameters is undefined
FederateNotExecutionMember - if the federate is not a member of an execution
SaveInProgress - if a save operation is in progress
RestoreInProgress - if a restore operation is in progress
RTIinternalError - if an internal error occurred in the run-time infrastructure

sendInteraction

public void sendInteraction(ExecutiveClientAmbassador eca,
                            InteractionClassHandle theInteraction,
                            ParameterHandleValueMap theParameters,
                            byte[] userSuppliedTag,
                            TransportationType theTransport,
                            OrderType sentOrdering,
                            LogicalTime theTime)
                     throws InteractionClassNotPublished,
                            InteractionClassNotDefined,
                            InteractionParameterNotDefined,
                            FederateNotExecutionMember,
                            SaveInProgress,
                            RestoreInProgress,
                            RTIinternalError
Sends an interaction received from a federate.

Parameters:
eca - the executive client ambassador of the connected federate
theInteraction - the interaction class handle
theParameters - the parameters of the interaction
userSuppliedTag - the user-supplied tag associated with the event
theTransport - the transportation type with which the interaction was sent
sentOrdering - the type of ordering with which the interaction was sent
theTime - the logical time associated with the interaction
Throws:
InteractionClassNotPublished
InteractionClassNotDefined
InteractionParameterNotDefined
FederateNotExecutionMember
SaveInProgress
RestoreInProgress
RTIinternalError

requestAttributeValueUpdate

public void requestAttributeValueUpdate(ObjectInstanceHandle theObject,
                                        AttributeHandleSet theAttributes,
                                        byte[] userSuppliedTag)
                                 throws ObjectInstanceNotKnown,
                                        AttributeNotDefined,
                                        FederateNotExecutionMember,
                                        SaveInProgress,
                                        RestoreInProgress,
                                        RTIinternalError
Requests an attribute value update.

Specified by:
requestAttributeValueUpdate in interface RTIambassador
Overrides:
requestAttributeValueUpdate in class XRTIAmbassador
Parameters:
theObject - the object with which the attributes are associated
theAttributes - the set of attributes to be updated
userSuppliedTag - a user-supplied tag to associated with the request
Throws:
ObjectInstanceNotKnown - if the object instance is unknown
AttributeNotDefined - if one of the attributes is undefined
FederateNotExecutionMember - if the federate is not a member of an execution
SaveInProgress - if a save operation is in progress
RestoreInProgress - if a restore operation is in progress
RTIinternalError - if an internal error occurred in the run-time infrastructure

toString

public java.lang.String toString()
Returns a string representation of the FederationExecutionAmbassador.

Returns:
a string representation of the FederationExecutionAmbassador

getExecutiveClientAmbassadors

protected java.util.Vector getExecutiveClientAmbassadors()
Returns the list of registered executive client ambassadors.

Returns:
the list of registered executive client ambassadors

allZeroLookaheadFederatesRestricted

protected boolean allZeroLookaheadFederatesRestricted(ExecutiveClientAmbassador eca)
Returns true if all zero lookahead federates in current federation execution are subject of zero lookahead restriction, false otherwise.

Parameters:
eca - the executive client ambassador of the requesting federate
Returns:
true if all zero lookahead federates in current federation execution are subject of zero lookahead restriction, false otherwise.

computeAllGaltValues

private void computeAllGaltValues(ExecutiveClientAmbassador eca)
Performs computation of the Greatest Available Logical Time (GALT) for all federates in current federation execution.

Parameters:
eca - the executive client ambassador of the requesting federate

sendAllPossibleTimeAdvanceGrants

private void sendAllPossibleTimeAdvanceGrants(ExecutiveClientAmbassador eca)
                                       throws FederateInternalError
Sends all possible timeAdvanceGrant callbacks to all federates in current federation execution.

Parameters:
eca - the executive client ambassador of the requesting federate
Throws:
FederateInternalError

handleTimeRequest

protected void handleTimeRequest(ExecutiveClientAmbassador eca)
                          throws FederateInternalError
Handles time request received from a federate. It is called always when federate seeks to advance its time.

Parameters:
eca - the executive client ambassador of the requesting federate
Throws:
FederateInternalError

registerFederationSynchronizationPoint

public boolean registerFederationSynchronizationPoint(ExecutiveClientAmbassador eca,
                                                      java.lang.String synchronizationPointLabel,
                                                      byte[] userSuppliedTag,
                                                      FederateHandleSet synchronizationSet)
Registers a federation synchronization point.

Parameters:
eca - the executive client ambassador
synchronizationPointLabel - the label of the synchronization point
userSuppliedTag - a user-supplied tag to associate with the operation
synchronizationSet - the set of federates to synchronize
Returns:
true if the synchronization point registration has succeeded, false otherwise

synchronizationPointAchieved

public void synchronizationPointAchieved(ExecutiveClientAmbassador eca,
                                         java.lang.String synchronizationPointLabel)
Notifies the run-time infrastructure that a synchronization point has been achieved.

Parameters:
eca - the executive client ambassador
synchronizationPointLabel - the label of the synchronization point