28 #ifndef _mtsGenericObject_h
29 #define _mtsGenericObject_h
40 #endif // CISST_HAS_JSON
84 AutomaticTimestampMember(true),
90 TimestampMember(timestamp),
91 AutomaticTimestampMember(automaticTimestamp),
98 TimestampMember(other.TimestampMember),
99 AutomaticTimestampMember(other.AutomaticTimestampMember),
100 ValidMember(other.ValidMember)
112 bool SetTimestampIfAutomatic(
double timestamp);
118 virtual void ToStream(std::ostream & outputStream)
const;
121 virtual void ToStreamRaw(std::ostream & outputStream,
const char delimiter =
' ',
122 bool headerOnly =
false,
const std::string & headerPrefix =
"")
const;
126 virtual bool FromStreamRaw(std::istream & inputStream,
const char delimiter =
' ');
129 virtual void SerializeRaw(std::ostream & outputStream)
const;
139 double Scalar(
const size_t index)
const throw (std::out_of_range);
142 std::string
ScalarDescription(
const size_t index,
const std::string & userDescription =
"")
const throw (std::out_of_range);
170 template <>
void CISST_EXPORT cmnDataJSON<mtsGenericObject>::DeSerializeText(
mtsGenericObject & data,
const Json::Value & jsonValue)
throw (std::runtime_error);
171 #endif // CISST_HAS_JSON
173 #endif // _mtsGenericObject_h
#define CISST_EXPORT
Definition: cmnExportMacros.h:50
Declaration of cmnSerializer and functions cmnSerializeRaw.
virtual bool ScalarNumberIsFixed(void) const
Definition: cmnGenericObject.h:136
Base class for high level objects.
Definition: cmnGenericObject.h:51
virtual double Scalar(const size_t CMN_UNUSED(index)) const
Definition: cmnGenericObject.h:143
Base class for data object in cisstMultiTask.
Definition: mtsGenericObject.h:56
virtual ~mtsGenericObject(void)
Definition: mtsGenericObject.h:104
virtual std::string ScalarDescription(const size_t CMN_UNUSED(index), const std::string &CMN_UNUSED(userDescription)) const
Definition: cmnGenericObject.h:152
mtsGenericObject(void)
Definition: mtsGenericObject.h:81
mtsGenericObject(const mtsGenericObject &other)
Definition: mtsGenericObject.h:96
virtual void SerializeRaw(std::ostream &outputStream) const
virtual void ToStream(std::ostream &outputStream) const
Defines cmnGenericObject.
virtual size_t ScalarNumber(void) const
Definition: cmnGenericObject.h:127
Definition: cmnDataFunctions.h:53
virtual void ToStreamRaw(std::ostream &outputStream, const char delimiter= ' ', bool headerOnly=false, const std::string &headerPrefix="") const
#define CMN_DECLARE_MEMBER_AND_ACCESSORS(memberType, memberName)
Definition: cmnAccessorMacros.h:70
Declaration of cmnDeSerializer and functions cmnDeSerializeRaw.
mtsGenericObject(double timestamp, bool automaticTimestamp, bool valid)
Definition: mtsGenericObject.h:89
virtual void DeSerializeRaw(std::istream &inputStream)
virtual bool FromStreamRaw(std::istream &inputStream, const char delimiter= ' ')