class
IntermediateSerializer
Public
Constructors
IntermediateSerializer
Methods
Encode
Encodes an IReflectable object into an intermediate representation.
Decode
Decodes an intermediate representation of a serialized object into the actual object.
Internal
Methods
SerializeIterableField
Serializes an entire field from the provided reflectable object.
Field must support RTTI iterators.
- object
- Object that contains the field to serialize.
- rttiInstance
- Type information describing .
- field
- Field to serialize.
- flags
- Flags controlling the serialization process.
Returns: Serialized field, or null if the field data is null.
SerializeDataBlockField
Serializes a data block field entry from a reflectable object into a SerializedInstance.
SerializeElement
Serializes an element at the provided iterator location.
- object
- Object that contains the field to serialize.
- rttiInstance
- Type information describing .
- field
- Field from which the element is being serialized.
- iterator
- Iterator pointing to the location of the element to serialize.
- flags
- Flags controlling the serialization process.
Returns: Serialized element, or null if the source element is null.
SerializeTupleElement
Serializes a single tuple element from the provided iterator location.
- object
- Object that contains the field to serialize.
- rttiInstance
- Type information describing .
- field
- Field from which the element is being serialized.
- iterator
- Iterator pointing to the location of the element to serialize.
- tupleElementIndex
- Tuple index to serialize. e.g. if element is of std::pair <K , V> type, index 0 would represent K and index 1 would represent V. Should be 0 if the iterator element is not a tuple type.
- flags
- Flags controlling the serialization process.
Returns: Serialized tuple element, or null if the source element is null.
DeserializeElement
Deserializes a single field, array or map entry from the provided field, at the provided iterator location.
DeserializeElement
Similar to DeserializeElement overload accepting an iterator, except accepts a pre-allocated output field value in which to write to.
DeserializeTupleElement
Decodes and writes it into at the specified tuple element index.
Private
Methods
DeserializeReflectableObject
Deserializes a single IReflectable object.
GetOrDeserializeReflectableObject
Attempts to retrieve a previously deserialized reflectable object from the deserialized object map.
If not present, deserializes the object and adds it to the deserializes object map, and returns the new object.
GetReflectableObject
Attempts to retrieve a previously deserialized reflectable object.
SerializeReflectableObject
Serializes a single IReflectable object.
GetOrSerializeReflectableObject
Attempts to retrieve a previously serialized object for the provided reflectable object, or if not found, serializes the object.