MAK Data Logger API Documentation for DIS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
hlaStateObject.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 1992-2016 VT MAK
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <lgrSim/lgrSim.h>
13 
14 #include <lgrCore/stateObject.h>
15 #include <lgrUtil/absoluteTime.h>
16 #include "hlaMessageFactory.h"
18 
19 #include <list>
20 #include <map>
21 
22 #include <vl/rtiCompatibility.h>
23 
24 namespace MAKLogger
25 {
26  class DtLgrHlaMessage;
27  class DtLgrHlaMessageState;
28  class DtLgrHlaSimulationManager;
29 
33  {
34  public:
35 
38 
39  void update(DtAbsoluteTime time, const DtLgrHandleValueReferenceMap* attributes);
40 
41  //Generate a list of timed AHVPSets.
42  void generate(DtTimedHandleValueMapList& outputList);
43 
44  typedef std::map<DtLgrHlaHandle,DtHlaTimeStampedAttribute*> HandleTimedAttributeMap;
45  const HandleTimedAttributeMap& attributes() const;
46 
47  protected:
48 
50  };
51 
55  {
56 
57  public:
58 
60  DT_VIRTUAL_CTR(DtHlaStateObject,(DtLgrHlaMessageState&, const DtPacket&))
61 
62 
64 
65 
66  virtual ~DtHlaStateObject();
67 
69  virtual bool isEntity() const;
70 
72  virtual bool isAggregate() const;
73 
75  virtual DtU64 uniqueId() const;
76 
78  virtual DtU64 uniqueId(const DtHlaObject* object) const;
79 
81  virtual const DtString& name() const;
82 
84  virtual DtU64 packetId(const DtPacket& packet) const;
85 
88  virtual void setPacketId(DtU64,DtPacket&) const;
89 
92  virtual DtPacket* createUpdate(const DtAbsoluteTime* time) const;
93 
96  virtual DtPacket* createUpdates(const DtAbsoluteTime* time) const;
97 
99  virtual DtPacket* createRemoval(const DtAbsoluteTime& currentTime) const;
100 
102  virtual bool packetForMe(const DtPacket&) const;
103 
105  virtual void updateViaPacket(const DtPacket&);
106 
108  virtual DtHlaTimeStampledStateRep* attributes();
109 
111  virtual const DtRegionDescSet& regionSet() const;
112 
113  inline DtLgrHlaHandle objectHandle() const{ return myObjectHandle;}
114  inline DtLgrHlaHandle classHandle() const{ return myClassHandle;}
115  inline const DtString& tag() const { return myTag;}
116 
117  protected:
118 
119  DtLgrHlaHandle myObjectHandle;
120  DtLgrHlaHandle myClassHandle;
121  DtString myName;
122  DtString myTag;
123 
124  DtLgrHlaMessageState* myState;
126  DtRegionDescSet myRegions;
129 
130  mutable const DtBaseObjClassDesc* myClassDesc;
131 
132  };
133 
134 }
135 
bool myIsUpdateFromPast
Definition: hlaStateObject.h:128
std::map< DtLgrHlaHandle, DtHlaTimeStampedAttribute * > HandleTimedAttributeMap
Definition: hlaStateObject.h:44
Defines IMPORT/EXPORT macros for lgrSim library.
#define DT_DLL_LGRSIM
Definition: lgrSim.h:21
#define DT_VIRTUAL_BASE_CTR(BASE_NAME, ARG_TYPES_LIST)
Declare a Virtual Base Constructor Create using DT_VIRTUAL_CTR(CLASS_NAME,ARG_TYPES_LIST) Where BASE_...
Definition: virtualConstructor.h:118
HLA Attributes stored with a timestamp per attribute.
Definition: hlaStateObject.h:32
#define DT_VIRTUAL_CTR(CLASS_NAME, ARG_TYPES_LIST)
Declare a Virtual Constructor Create using DT_VIRTUAL_CTR(CLASS_NAME,ARG_TYPES_LIST) Where CLASS_NAME...
Definition: virtualConstructor.h:34
A generic object that has state.
Definition: stateObject.h:27
Contains MAKLogger::DtHlaTimeStampedAttribute class.
DtHlaTimeStampledStateRep * myAttributes
Definition: hlaStateObject.h:125
Contains MAKLogger::DtLgrHlaMessageFactory class.
DtRegionDescSet myRegions
Definition: hlaStateObject.h:126
const DtBaseObjClassDesc * myClassDesc
Definition: hlaStateObject.h:130
Contains MAKLogger::DtAbsoluteTime and MAKLogger::DtRelativeTime classes.
HandleTimedAttributeMap myAttributes
Definition: hlaStateObject.h:49
DtLgrHlaHandle objectHandle() const
Definition: hlaStateObject.h:113
A generic packed of typed binary data.
Definition: packet.h:41
const DtString & tag() const
Definition: hlaStateObject.h:115
A HLA state object which represents any HLA object.
Definition: hlaStateObject.h:54
DtLgrHlaHandle myObjectHandle
Definition: hlaStateObject.h:119
DtLgrHlaHandle classHandle() const
Definition: hlaStateObject.h:114
The Abstract message state maintained by the logger.
Definition: messageState.h:33
DtAbsoluteTime myLastUpdateTime
Definition: hlaStateObject.h:127
DtLgrHlaHandle myClassHandle
Definition: hlaStateObject.h:120
Contains MAKLogger::DtStateObject class.
DtString myName
Definition: hlaStateObject.h:121
DtString myTag
Definition: hlaStateObject.h:122
Absolute Time, a particular measured instance in time, could be thought of as a set of relative times...
Definition: absoluteTime.h:82
DtLgrHlaMessageState * myState
Definition: hlaStateObject.h:124

Document ID: Generated on Thu Jul 14 15:45:33 EDT 2022 from SVN revision 244827
Copyright © 2021 MAK Technologies. All Rights Reserved (www.mak.com)