Dumps/serializes the content of s and its array members, using the given serializer object. The serializer object needs the following methods:
void open ( D, cstring name );
void close ( D, cstring name );
void serialize ( T ) ( D, ref T item, cstring name );
void openStruct ( D, cstring name );
void closeStruct ( D, cstring name );
void serializeArray ( T ) ( D, cstring name, T[] array );
Optional:
void serializeStaticArray ( T ) ( D, cstring name, T[] array );
If this methond doesn't exist, serializeArray will be used.
void openStructArray ( T ) ( D, cstring name, T[] array );
void closeStructArray ( T ) ( D, cstring name, T[] array );
Unfortunately, as some of these methods are templates, it's not possible to make an interface for it. But the compiler will let you know whether a given serializer object is suitable or not
See ocean.io.serialize.JsonStructSerializer for an example.
type of struct to serialize
type of serializer object
tuple of data parameters passed to the serializer
struct instance (pointer)
object to do the serialization
parameters for serializer
See Implementation
Dumps/serializes the content of s and its array members, using the given serializer object. The serializer object needs the following methods:
void open ( D, cstring name );
void close ( D, cstring name );
void serialize ( T ) ( D, ref T item, cstring name );
void openStruct ( D, cstring name );
void closeStruct ( D, cstring name );
void serializeArray ( T ) ( D, cstring name, T[] array );
Optional:
void serializeStaticArray ( T ) ( D, cstring name, T[] array );
If this methond doesn't exist, serializeArray will be used.
void openStructArray ( T ) ( D, cstring name, T[] array );
void closeStructArray ( T ) ( D, cstring name, T[] array );
Unfortunately, as some of these methods are templates, it's not possible to make an interface for it. But the compiler will let you know whether a given serializer object is suitable or not
See ocean.io.serialize.JsonStructSerializer for an example.