|
virtual bool | serialize (const ISerializable *serializable)=0 |
| Writes a serializable object to the serializer. More...
|
|
virtual bool | write (const bool *value, Size count=1)=0 |
| Writes values of type bool to the serializer. More...
|
|
virtual bool | write (const Uint8 *value, Size count=1)=0 |
| Writes values of type mi::Uint8 to the serializer. More...
|
|
virtual bool | write (const Uint16 *value, Size count=1)=0 |
| Writes values of type mi::Uint16 to the serializer. More...
|
|
virtual bool | write (const Uint32 *value, Size count=1)=0 |
| Writes values of type mi::Size to the serializer. More...
|
|
virtual bool | write (const Uint64 *value, Size count=1)=0 |
| Writes values of type mi::Uint64 to the serializer. More...
|
|
virtual bool | write (const Sint8 *value, Size count=1)=0 |
| Writes values of type mi::Sint8 to the serializer. More...
|
|
virtual bool | write (const Sint16 *value, Size count=1)=0 |
| Writes values of type mi::Sint16 to the serializer. More...
|
|
virtual bool | write (const Sint32 *value, Size count=1)=0 |
| Writes values of type mi::Sint32 to the serializer. More...
|
|
virtual bool | write (const Sint64 *value, Size count=1)=0 |
| Writes values of type mi::Sint64 to the serializer. More...
|
|
virtual bool | write (const Float32 *value, Size count=1)=0 |
| Writes values of type mi::Float32 to the serializer. More...
|
|
virtual bool | write (const Float64 *value, Size count=1)=0 |
| Writes values of type mi::Float64 to the serializer. More...
|
|
virtual void | reserve (Size capacity)=0 |
| Gives a hint to the serializer about the required buffer size. More...
|
|
virtual void | flush ()=0 |
| Flushes the so-far serialized data. More...
|
|
virtual bool | write (const Tag_struct *value, Size count=1)=0 |
| Writes values of type mi::neuraylib::Tag_struct to the serializer. More...
|
|
virtual Uint32 | retain () const =0 |
| Increments the reference count. More...
|
|
virtual Uint32 | release () const =0 |
| Decrements the reference count. More...
|
|
virtual const IInterface * | get_interface (const Uuid &interface_id) const =0 |
| Acquires a const interface from another. More...
|
|
template<class T> |
const T * | get_interface () const |
| Acquires a const interface from another. More...
|
|
virtual IInterface * | get_interface (const Uuid &interface_id)=0 |
| Acquires a mutable interface from another. More...
|
|
template<class T> |
T * | get_interface () |
| Acquires a mutable interface from another. More...
|
|
virtual Uuid | get_iid () const =0 |
| Returns the interface ID of the most derived interface. More...
|
|
|
typedef Interface_declare< id1, ... > | Self |
| Own type. More...
|
|
typedef Uuid_t< id1, ... > | IID |
| Declares the interface ID (IID) of this interface. More...
|
|
typedef Uuid_t<0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0> | IID |
| Declares the interface ID (IID) of this interface. More...
|
|
static bool | compare_iid (const Uuid &iid) |
| Compares the interface ID iid against the interface ID of this interface and of its ancestors. More...
|
|
static bool | compare_iid (const Uuid &iid) |
| Compares the interface ID iid against the interface ID of this interface. More...
|
|
Target for serializing objects to byte streams.
The serializer can be used to serialize objects to a byte stream. It is used when serializing objects to disk, to a network connection, etc.
Arrays of values of a particular type can be serialized with a single call by passing the array size as the count
parameter. The address of subsequent array elements is obtained by pointer arithmetic.
virtual void mi::neuraylib::ISerializer::flush |
( |
| ) |
|
|
pure virtual |
Flushes the so-far serialized data.
The meaning of flushing depends on the context in which the serializer is used. If flushing is not supported in some context, nothing happens. If flushing is supported in some context, it typically means to process the already serialized data in the same way as the entire data at the end of the serialization would have been processed. For example, large buffers whose content is produced slowly over time can be subdivided into smaller chunks which can then be processed earlier than the entire buffer.