MAK RTIspy API Documentation for HLA 1516
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
logicalTimeImplUnsignedInteger.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2005 MaK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 /*******************************************************************************
6 ** $RCSfile: logicalTimeImplUnsignedInteger.h,v $ $Revision: 1.2 $ $State: Exp $
7 *******************************************************************************/
8 
9 #ifndef RTI_LogicalTimeImplUnsignedInteger_H_
10 #define RTI_LogicalTimeImplUnsignedInteger_H_
11 
12 #include <RTI/LogicalTime.h>
14 
16 {
17 public:
18  static std::wstring theImplementationName;
19 
20 public:
21  // Constructors
26 
27  // Destructor
29  throw ();
30 
31  // Basic accessors/mutators
32  virtual void setInitial();
33  virtual bool isInitial() const;
34 
35  virtual void setFinal();
36  virtual bool isFinal() const;
37 
38  // Assignment
39  virtual rti1516::LogicalTime& operator= (rti1516::LogicalTime const & value)
40  throw (
41  rti1516::InvalidLogicalTime);
42 
43  virtual
44  rti1516::LogicalTime&
45  operator+= (rti1516::LogicalTimeInterval const & addend)
46  throw (
47  rti1516::IllegalTimeArithmetic,
48  rti1516::InvalidLogicalTimeInterval);
49 
50  virtual
51  rti1516::LogicalTime&
52  operator-= (rti1516::LogicalTimeInterval const & subtrahend)
53  throw (
54  rti1516::IllegalTimeArithmetic,
55  rti1516::InvalidLogicalTimeInterval);
56 
57  virtual
58  bool
59  operator> (rti1516::LogicalTime const & value) const
60  throw (
61  rti1516::InvalidLogicalTime);
62 
63  virtual
64  bool
65  operator< (rti1516::LogicalTime const & value) const
66  throw (
67  rti1516::InvalidLogicalTime);
68 
69  virtual
70  bool
71  operator== (rti1516::LogicalTime const & value) const
72  throw (
73  rti1516::InvalidLogicalTime);
74 
75  virtual
76  bool
77  operator>= (rti1516::LogicalTime const & value) const
78  throw (
79  rti1516::InvalidLogicalTime);
80 
81  virtual
82  bool
83  operator<= (rti1516::LogicalTime const & value) const
84  throw (
85  rti1516::InvalidLogicalTime);
86 
87  // Generates an encoded value that can be used to send
88  // LogicalTimes to other federates in updates or interactions
89  virtual rti1516::VariableLengthData encode() const;
90 
91  // Alternate encode for directly filling a buffer
92  virtual unsigned long encodedLength() const;
93  virtual unsigned long encode(void* buffer, unsigned long bufferSize) const
94  throw (rti1516::CouldNotEncode);
95 
96  // Decode VariableLengthData into self
97  virtual void decode(rti1516::VariableLengthData const & VariableLengthData)
98  throw (
99  rti1516::InternalError,
100  rti1516::CouldNotDecode);
101 
102  // Alternate decode that reads directly from a buffer
103  virtual void decode(void* buffer, unsigned long bufferSize)
104  throw (
105  rti1516::InternalError,
106  rti1516::CouldNotDecode);
107 
108  virtual std::wstring toString() const;
109 
110  // Returns the name of the implementation, as needed by
111  // createFederationExecution.
112  virtual std::wstring implementationName() const;
113 
114 
115 public:
116  //-----------------------------------------------------------------
117  // Implementation functions
118  //-----------------------------------------------------------------
119  virtual DtLtU64 getTime() const;
120 
121  //-----------------------------------------------------------------
122  // Implementation operators
123  //-----------------------------------------------------------------
125  throw (rti1516::InvalidLogicalTime);
126 
127  virtual rti1516::LogicalTime& operator= (DtLtU64 const & value)
128  throw (rti1516::InvalidLogicalTime);
129 
130  virtual rti1516::LogicalTime& operator+= (DtLtU64 const & value)
131  throw (rti1516::InvalidLogicalTime);
132 
133  virtual rti1516::LogicalTime& operator-= (DtLtU64 const & value)
134  throw (rti1516::InvalidLogicalTime);
135 
136  virtual bool operator== (DtLtU64 const & value) const
137  throw (rti1516::InvalidLogicalTime);
138 
139  virtual bool operator!= (DtLtU64 const & value) const
140  throw (rti1516::InvalidLogicalTime);
141 
142  virtual bool operator!= (rti1516::LogicalTime const & value) const
143  throw (rti1516::InvalidLogicalTime);
144 
145  virtual bool operator> (DtLtU64 const & value) const
146  throw (rti1516::InvalidLogicalTime);
147 
148  virtual bool operator< (DtLtU64 const & value) const
149  throw (rti1516::InvalidLogicalTime);
150 
151  virtual bool operator>= (DtLtU64 const & value) const
152  throw (rti1516::InvalidLogicalTime);
153 
154  virtual bool operator<= (DtLtU64 const & value) const
155  throw (rti1516::InvalidLogicalTime);
156 
157  private:
158 
160 
161  //-----------------------------------------------------------------
162  // Implementation member variables
163  //-----------------------------------------------------------------
164  DtLtU64 myLogicalTime;
165  DtLtU64 myZero;
166  DtLtU64 myEpsilon;
167  DtLtU64 myPositiveInfinity;
168 
169 };
170 
171 
172 #endif // RTI_LogicalTimeImplUnsignedInteger_H_
173 
std::string toString(const std::wstring &inString)
Definition: objParams13.h:16
#define RTI_EXPORT_FEDTIME
Definition: SpecificConfig.h:56
unsigned long long DtLtU64
-------—— Implementation for a long long (64 bytes unsigned)
Definition: logicalTimeIntervalImplUnsignedInteger.h:39
Definition: logicalTimeImplUnsignedInteger.h:15
Definition: logicalTimeIntervalImplUnsignedInteger.h:44
Definition: LogicalTime.h:27
static std::wstring theImplementationName
Definition: logicalTimeImplUnsignedInteger.h:18

Document ID: Generated on Sun Jul 20 16:15:30 EDT 2025 from SVN revision 277985
Copyright © 2005-2025 MAK Technologies Inc. All Rights Reserved (www.mak.com)