19template <
class T>
using Queue = std::queue<T, std::deque<T, STLAllocator<T>>>;
39 result = stream->
Write((
void *)&inObject, GetRTTI(&inObject));
51 stream.open(inFileName, std::ofstream::out | std::ofstream::trunc | std::ofstream::binary);
52 if (!stream.is_open())
54 return sWriteObject(stream, inType, inObject);
62 bool Write(
const void *inObject,
const RTTI *inRTTI);
63 void WriteObject(
const void *inObject);
64 void QueueRTTI(
const RTTI *inRTTI);
65 void WriteRTTI(
const RTTI *inRTTI);
81 ObjectInfo() : mIdentifier(0), mRTTI(
nullptr) { }
82 ObjectInfo(
Identifier inIdentifier,
const RTTI *inRTTI) : mIdentifier(inIdentifier), mRTTI(inRTTI) { }
93 Identifier mNextIdentifier = sNullIdentifier + 1;
94 IdentifierMap mIdentifierMap;
95 ObjectQueue mObjectQueue;
97 ClassQueue mClassQueue;
#define JPH_EXPORT
Definition: Core.h:227
#define JPH_SUPPRESS_WARNINGS_STD_BEGIN
Definition: Core.h:372
#define JPH_SUPPRESS_WARNINGS_STD_END
Definition: Core.h:384
#define JPH_NAMESPACE_END
Definition: Core.h:367
#define JPH_NAMESPACE_BEGIN
Definition: Core.h:361
std::queue< T, std::deque< T, STLAllocator< T > > > Queue
Definition: ObjectStreamOut.h:19
std::unordered_map< Key, T, Hash, KeyEqual, STLAllocator< pair< const Key, T > > > UnorderedMap
Definition: UnorderedMap.h:13
std::unordered_set< Key, Hash, KeyEqual, STLAllocator< Key > > UnorderedSet
Definition: UnorderedSet.h:13
Interface class for writing to an object stream.
Definition: ObjectStream.h:74
virtual void WritePointerData(const RTTI *inRTTI, const void *inPointer)=0
virtual void WriteClassData(const RTTI *inRTTI, const void *inInstance)=0
uint32 Identifier
Identifier for objects.
Definition: ObjectStream.h:31
EStreamType
Stream type.
Definition: ObjectStream.h:21
Definition: ObjectStreamOut.h:24
bool Write(const void *inObject, const RTTI *inRTTI)
Definition: ObjectStreamOut.cpp:33
static bool sWriteObject(const char *inFileName, ObjectStream::EStreamType inType, const T &inObject)
Main function to write an object to a file.
Definition: ObjectStreamOut.h:48
static bool sWriteObject(ostream &inStream, ObjectStream::EStreamType inType, const T &inObject)
Main function to write an object to a stream.
Definition: ObjectStreamOut.h:31
static ObjectStreamOut * Open(EStreamType inType, ostream &inStream)
Static constructor.
Definition: ObjectStreamOut.cpp:22
ostream & mStream
Definition: ObjectStreamOut.h:76