hlaSimInput.h
Go to the documentation of this file.
00001 /******************************************************************************
00002 ** Copyright (c) 1992-2010 VT MAK
00003 ** All rights reserved.
00004 ******************************************************************************/
00005 
00009 
00010 #ifndef hlaSimInput_H_
00011 #define hlaSimInput_H_
00012 
00013 #if DtHLA
00014 
00015 #include "lgrSim.h"
00016 #include "lgrSimInput.h"
00017 #include "lgrHlaAttribute.h"
00018 #include "hlaMessageFactory.h"
00019 
00020 #include <vl/rtiNamespace.h>
00021 #include <vl/rtiCompatibility.h>
00022 
00023 #include <list>
00024 #include <map>
00025 
00026 class DtHlaObject;
00027 class DtInteraction;
00028 class DtStateMsg;
00029 class DtBaseEntityStateRepository;
00030 
00031 namespace MAKLogger
00032 {
00033    class DtLgrHlaSimulationManager;
00034    class DtMessageBuffer;
00035    class DtLgrHlaMessageIOInfo;
00036 
00040    class DT_DLL_LGRSIM DtLgrHlaSimInput : public DtLgrSimInput
00041    {
00042    public:
00043 
00044       DT_VIRTUAL_CTR(DtLgrHlaSimInput, (DtLgrHlaSimulationManager& manager))
00045 
00046       virtual ~DtLgrHlaSimInput();
00047 
00048       virtual void activateImplementation();
00049       virtual void deactivateImplementation();
00050 
00052       virtual void disconnecting();
00053 
00054       virtual const DtMessageIOInfo* info() const;
00055 
00057       virtual DtAbsoluteTime inputTime() const;
00058 
00059       virtual void tick();
00060 
00061       static void decodeIsPartOf_RPR_20014( DtBaseEntityStateRepository* stateRep,
00062          const RTI::AttributeHandleValuePairSet& attrs,
00063          int pairSetIndex );
00064 
00065    protected:
00066 
00067       static void discoverObjCb(DtHlaObject* object,void* usr);
00068       virtual void discoverObject(DtHlaObject* object);
00069 
00070       static void receiveInterCb( DtInteraction* inter, void* usr );
00071       virtual void receiveInteraction(const DtInteraction * interaction);
00072 
00075       virtual int getInteractionRegionSet(const DtInteraction *interaction, DtRegionDescSet& regionSet);
00076 
00077       static void reflectCb(const DtStateMsg& msg, DtHlaObject* obj, void* usr );
00078       virtual void reflect(const DtStateMsg& msg, DtHlaObject* obj);
00079 
00082       virtual int getObjectRegionSet(DtRegionDescSet& regionSet);
00083 
00084       static void removeObjCb(DtHlaObject* object,void* usr);
00085       virtual void removeObject(DtHlaObject* object);
00086 
00087       virtual void startListening();
00088       virtual void stopListening();
00089 
00090 #if DtHLA_1516
00091       typedef std::map<RTI::ObjectInstanceHandle,DtLgrHlaHandle> ObjectInstanceMap;
00092 #else
00093       typedef std::map<RTI::ObjectHandle,DtLgrHlaHandle> ObjectInstanceMap;
00094 #endif
00095 
00096       DtLgrHlaSimulationManager& myHlaManager;
00097 
00098       std::map<DtHlaObject*, DtAbsoluteTime> myTimeoutTimeMap;
00099 
00100       ObjectInstanceMap myObjectInstanceMap;
00101       DtLgrHlaHandle myFreeInstanceHandle;
00102 
00103       bool myCurrentlyListeningFlag;
00104 
00105       DtLgrHlaMessageIOInfo* myInfo;
00106    };
00107 
00108 }
00109 
00110 #endif
00111 #endif

Document ID: Generated on Tue Oct 11 19:41:03 EDT 2011 from SVN revision 107422
Copyright © 2005-2011 VT MÄK Inc. All Rights Reserved (www.mak.com)