![]() |
VR-Link API Documentation for HLA 1.3
|
00001 /********************************************************************* 00002 ** Copyright (c) 2009 MaK Technologies, Inc. 00003 ** All rights reserved. 00004 *********************************************************************/ 00005 #pragma once 00006 00007 #if DtHLA 00008 #if DtHLA_1516 00009 #if !DtHLA_1516_EVOLVED 00010 00011 #include <vl/vrlFedAmb1516.h> 00012 00013 class DtDdmFederateAmbassador : public DtVrlFederateAmbassador 00014 { 00015 public: 00016 struct DtRegionInfo 00017 { 00018 unsigned long lowerXBound; 00019 unsigned long lowerYBound; 00020 unsigned long upperXBound; 00021 unsigned long upperYBound; 00022 bool infoSet; 00023 }; 00024 00025 DtDdmFederateAmbassador(); 00026 00027 virtual ~DtDdmFederateAmbassador() throw(); 00028 00029 virtual void discoverObjectInstance( 00030 RTI::ObjectInstanceHandle theObject, 00031 RTI::ObjectClassHandle theObjectClass, 00032 std::wstring const & theObjectInstanceName) 00033 throw (RTI::CouldNotDiscover, 00034 RTI::ObjectClassNotKnown, 00035 RTI::FederateInternalError); 00036 00037 virtual void reflectAttributeValues( 00038 RTI::ObjectInstanceHandle theObject, 00039 RTI::AttributeHandleValueMap const & theAttributeValues, 00040 RTI::VariableLengthData const & aTag, 00041 RTI::OrderType sentOrder, 00042 RTI::TransportationType theType, 00043 RTI::RegionHandleSet const & theSentRegionHandleSet) 00044 throw (RTI::ObjectInstanceNotKnown, 00045 RTI::AttributeNotRecognized, 00046 RTI::AttributeNotSubscribed, 00047 RTI::FederateInternalError); 00048 00049 virtual void removeObjectInstance( 00050 RTI::ObjectInstanceHandle theObject, 00051 RTI::VariableLengthData const & aTag, 00052 RTI::OrderType sentOrder) 00053 throw (RTI::ObjectInstanceNotKnown, 00054 RTI::FederateInternalError); 00055 00056 virtual void receiveInteraction( 00057 RTI::InteractionClassHandle theInteraction, 00058 RTI::ParameterHandleValueMap const & theParameterValues, 00059 RTI::VariableLengthData const & aTag, 00060 RTI::OrderType sentOrder, 00061 RTI::TransportationType theType, 00062 RTI::RegionHandleSet const & theSentRegionHandleSet) 00063 throw (RTI::InteractionClassNotRecognized, 00064 RTI::InteractionParameterNotRecognized, 00065 RTI::InteractionClassNotSubscribed, 00066 RTI::FederateInternalError); 00067 00068 00069 static DtVrlFederateAmbassador* create(); 00070 00071 virtual void setXHandle(RTI::DimensionHandle handle); 00072 virtual void setYHandle(RTI::DimensionHandle handle); 00073 00074 virtual DtRegionInfo regionInfoForObject(RTI::ObjectInstanceHandle handle) const; 00075 virtual DtRegionInfo lastInteractionRegion() const; 00076 00077 virtual void clearLastInteractionRegion(); 00078 00079 protected: 00080 00081 protected: 00082 std::map<RTI::ObjectInstanceHandle, DtRegionInfo> myHandleToRegionMap; 00083 DtRegionInfo myLastInteractionRegion; 00084 00085 RTI::DimensionHandle myXHandle; 00086 RTI::DimensionHandle myYHandle; 00087 00088 DtRegionInfo myEmptyRegionInfo; 00089 }; 00090 00091 #endif 00092 #endif 00093 #endif 00094 00095