MAK Data Logger API Documentation for HLA
hlaSimInput.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #ifndef hlaSimInput_H_
11 #define hlaSimInput_H_
12 
13 #if DtHLA
14 
15 #include "lgrSim.h"
16 #include "lgrSimInput.h"
17 #include "lgrHlaAttribute.h"
18 #include "hlaMessageFactory.h"
19 
20 #include <vl/rtiNamespace.h>
21 #include <vl/rtiCompatibility.h>
22 
23 #include <list>
24 #include <map>
25 
26 class DtHlaObject;
27 class DtInteraction;
28 class DtStateMsg;
29 class DtBaseEntityStateRepository;
30 class DtGenericAttributeDecoder;
31 class DtStateRepository;
32 
33 namespace MAKLogger
34 {
35  class DtLgrHlaSimulationManager;
36  class DtMessageBuffer;
37  class DtLgrHlaMessageIOInfo;
38 
43  {
44  public:
45 
47 
48  virtual ~DtLgrHlaSimInput();
49 
50  virtual void activateImplementation();
51  virtual void deactivateImplementation();
52 
54  virtual void disconnecting();
55 
56  virtual const DtMessageIOInfo* info() const;
57 
59  virtual DtAbsoluteTime inputTime() const;
60 
61  virtual void tick();
62 
63  static void decodeIsPartOf_RPR_20014( DtBaseEntityStateRepository* stateRep,
64  const RTI::AttributeHandleValuePairSet& attrs,
65  int pairSetIndex );
66 
67  protected:
68 
69  static void discoverObjCb(DtHlaObject* object,void* usr);
70  virtual void discoverObject(DtHlaObject* object);
71 
72  static void receiveInterCb( DtInteraction* inter, void* usr );
73  virtual void receiveInteraction(const DtInteraction * interaction);
74 
77  virtual int getInteractionRegionSet(const DtInteraction *interaction, DtRegionDescSet& regionSet);
78 
80  static void reflectCb(const DtStateMsg& msg, DtHlaObject* obj, void* usr );
81 
83  virtual void reflect(const DtStateMsg& msg, DtHlaObject* obj);
84 
87  virtual int getObjectRegionSet(DtRegionDescSet& regionSet);
88 
89  static void removeObjCb(DtHlaObject* object,void* usr);
90  virtual void removeObject(DtHlaObject* object, bool updateTimeout=true);
91 
92  virtual void startListening();
93  virtual void stopListening();
94 
97  virtual bool evaluateTrafficAnalyzerFilters(const DtHlaObject& obj) const;
98 
100  virtual void localDeleteObjectForRefresh(DtHlaObject* object);
101 
103  void checkRefresh();
104 
106  void checkTimeouts();
107 
109  void removeTimeout(DtHlaObject* object);
110 
111  protected:
112 
113 #if DtHLA_1516
114  typedef std::map<RTI::ObjectInstanceHandle,DtLgrHlaHandle> ObjectInstanceMap;
115  typedef std::map<DtString, RTI::ObjectInstanceHandle> NameObjectInstanceMap;
116 #else
117  typedef std::map<RTI::ObjectHandle,DtLgrHlaHandle> ObjectInstanceMap;
118  typedef std::map<DtString, RTI::ObjectHandle> NameObjectInstanceMap;
119 #endif
120  typedef std::map<DtHlaObject*, DtAbsoluteTime> TimeoutByObjectMap;
121  typedef std::set<DtHlaObject*> HlaObjectSet;
122  typedef std::map<DtAbsoluteTime, HlaObjectSet> TimeoutByTimeMap;
123 
125 
128 
129  typedef DtBoost::shared_ptr<DtStateRepository> DtStateRepositorySP;
130  typedef DtBoost::shared_ptr<DtGenericAttributeDecoder> DtGenericAttributeDecoderSP;
132  {
133  public:
135  virtual ~DtStateAndDecoder();
136  virtual void initialize(DtExerciseConn* exConn, DtObjClassDesc* classDesc);
137  virtual DtStateRepository* state();
138  virtual DtGenericAttributeDecoder* decoder();
139  protected:
142  };
143 
145  std::map<DtHlaObject*, DtStateAndDecoder> myStateAndDecoders;
146 
150 
152 
154  };
155 
156 }
157 
158 #endif
159 #endif

Document ID: Generated on Mon Jan 19 08:20:14 EST 2015 from SVN revision 149581
Copyright © 2005-2012 VT MÄK. All Rights Reserved (www.mak.com)