 |
AGX Dynamics
2.38.0.2
|
Go to the documentation of this file.
19 # pragma warning(push)
20 # pragma warning( disable : 4290 ) // C++ exception specification ignored except to indicate a function is not __declspec(nothrow)
81 std::istream& getStream();
118 size_t getVersion()
const;
120 virtual void read(
char& val);
121 virtual void read(
bool& val);
130 virtual void read(std::string& val);
133 virtual void read(
float& val);
134 virtual void read(
double& val);
137 virtual void read(
size_t& val );
169 virtual void read(
void* buf,
size_t len);
183 sObj = readObjectByRef();
185 *obj =
dynamic_cast<T*
>(sObj);
186 if (sObj != 0 && *obj == 0) {
189 T::getConstructClassId());
212 int getNumObjectsRead()
const;
215 bool getEndianMatch()
const;
221 DEFAULT = TRY_BY_REFERENCE
224 void setRestoreMode(RestoreMode mode);
225 RestoreMode getRestoreMode()
const;
227 virtual void beginSection(
const char* title)
override;
228 virtual void endSection(
const char* title)
override;
230 virtual void getAttribute(
const char *name,
double& value);
231 virtual void getAttribute(
const char *name,
float& value);
232 virtual void getAttribute(
const char *name,
bool& value);
233 virtual void getAttribute(
const char *name, std::string& value);
234 virtual void getAttribute(
const char *name,
char& value);
235 virtual void getAttribute(
const char *name,
agx::UInt16& value);
236 virtual void getAttribute(
const char *name,
agx::UInt64& value);
237 virtual void getAttribute(
const char *name,
agx::UInt32& value);
238 virtual void getAttribute(
const char *name,
agx::Int32& value);
239 virtual void getAttribute(
const char *name,
agx::Int8& value);
240 virtual void getAttribute(
const char *name,
agx::UInt8& value);
241 virtual void getAttribute(
const char *name,
agx::Uuid& value);
244 virtual void getAttribute(
const char *name,
size_t& value);
250 bool hasModification(
const char *str)
const;
266 template<
typename VECTOR_TYPE>
274 void readCompareBitSize();
276 virtual void readArchiveHeader();
277 virtual void readObjectHeader(
StorageMode& storageMode, StorageAgent*& agent);
278 virtual void readTypeHeader(StorageAgent*& agent);
281 virtual size_t getNumBytesRead()
const;
285 friend class StorageAgent;
314 agx::String getSerializationVersionStringMessage()
const;
316 void readHeaderData();
321 void readCorrectNumBytes(T& val);
333 agx::UInt8 m_generationVersion, m_majorVersion, m_minorVersion, m_patchVersion;
337 size_t m_numBytesRead;
338 int m_numObjectsRead;
349 void readModificationData();
365 template <
typename T>
378 template <
typename T>
398 template <
typename T>
409 template <
typename T>
413 #define DECLARE_INPUT_BASIC_TYPE(TYPE) \
414 AGXCORE_EXPORT inline agxStream::InputArchive& operator>>( InputArchive& in, InputVal<TYPE> val ) \
416 in.beginSection(val.m_name); \
417 in.read( val.m_obj ); \
418 in.endSection(val.m_name); \
421 inline InputVal<TYPE> in(const char *name, TYPE& obj) { return InputVal<TYPE>(name, obj); }
460 template <
typename T>
468 template <
typename T>
492 observerPtr = object;
498 # pragma warning(pop)
static AgXString format(const char *format,...)
C printf formatting of a string.
Abstract base class for input/output storage of Serializable classes.
This class is an abstract base class for all classes that can be stored and retrieved from an Archive...
Matrix class for rigid transformations (translation, rotation).
InputVal< T > in_val(const char *name, T &obj)
Create an object with a name and a reference to the object that should be restored.
A class holding 4 dimensional vectors and providing basic arithmetic.
Class for listening to the restore of Serializable objects.
agx::ref_ptr< InputArchive > InputArchiveRef
Smart pointer for observed objects, that automatically set pointers to them to null when they deleted...
InputRef< T > in(const char *name, T &obj)
Create an object with a name and a reference to the object that should be restored (usually a pointer...
virtual const char * getClassName() const
InputArchive & operator>>(InputArchive &in, InputVal< T > val)
Inheritance with partial specialization due to bug with ref_ptr containers.
Representation of a name string.
Specialized type of matrices for holding symmetric positive definite matrices.
Inheritance with partial specialization due to bug with ref_ptr containers.
void restoreRefPtr(agxStream::InputArchive &in, const char *name, agx::ref_ptr< T > &refPtr)
void restoreObserverPtr(agxStream::InputArchive &in, const char *name, agx::observer_ptr< T > &observerPtr)
bool AGXPHYSICS_EXPORT read(const std::string &filename, agxStream::SerializablePtrVector &readObjects)
Open and read serializable objects from a file on disk with previously stored objects.
This namespace contain classes for streaming classes into archives, ASCII, binary for storage (serial...
A UUID, or Universally unique identifier, is intended to uniquely identify information in a distribut...