iDRS™ SDK 16
Loading...
Searching...
No Matches
CSerialization_interface.h File Reference

Interface for CSerialization wrapper. More...

Go to the source code of this file.

Functions

CSerialization CSerialization_Create (const CIDRS argIdrs, enum SerializationFormat const evSerializationVersion, idrs_exception *pargException)
 Create the CSerialization instance.
 
CSerialization CSerialization_Create2 (const CIDRS argIdrs, idrs_exception *pargException)
 Create the CSerialization instance.
 
CPage CSerialization_LoadPage (const CSerialization argCSerialization, const idrs_string strFileName, idrs_exception *pargException)
 LoadPage loads a page from its serialized format.
 
CPage CSerialization_LoadPage2 (const CSerialization argCSerialization, IByteStream argStream, idrs_exception *pargException)
 LoadPage loads a page from its serialized format.
 
void CSerialization_SavePage (const CSerialization argCSerialization, const CPage argPage, const idrs_string strFileName, idrs_exception *pargException)
 SavePage saves a page object into its serialized format.
 
void CSerialization_SavePage2 (const CSerialization argCSerialization, const CPage argPage, IByteStream argStream, idrs_exception *pargException)
 SavePage saves a page object into its serialized format.
 
CPageContent CSerialization_LoadPageContent (const CSerialization argCSerialization, const idrs_string strFileName, idrs_exception *pargException)
 LoadPageContent loads page content from the given file.
 
CPageContent CSerialization_LoadPageContent2 (const CSerialization argCSerialization, IByteStream argStream, idrs_exception *pargException)
 LoadPageContent loads zones from the given stream.
 
void CSerialization_SavePageContent (const CSerialization argCSerialization, const CPageContent argPageContent, const idrs_string strFileName, idrs_exception *pargException)
 SavePage saves a page's content into its serialized format.
 
void CSerialization_SavePageContent2 (const CSerialization argCSerialization, const CPageContent argPageContent, IByteStream argStream, idrs_exception *pargException)
 SavePage saves a page's content into its serialized format.
 
void CSerialization_SetFormat (CSerialization argCSerialization, enum SerializationFormat const evSerializationVersion, idrs_exception *pargException)
 Set the serialization format which will be used when saving a page or its content.
 
enum SerializationFormat CSerialization_GetFormat (const CSerialization argCSerialization, idrs_exception *pargException)
 Get the serialization format which will be used when saving a page or its content.
 
void CSerialization_Destroy (CSerialization argCSerialization, idrs_exception *pargException)
 Destroys a CSerialization handle.
 

Detailed Description

Interface for CSerialization wrapper.

Function Documentation

◆ CSerialization_Create()

CSerialization CSerialization_Create ( const CIDRS  argIdrs,
enum SerializationFormat const  evSerializationVersion,
idrs_exception *  pargException 
)

Create the CSerialization instance.

Parameters
argIdrsThe iDRS instance
evSerializationVersionThe format to save to
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ CSerialization_Create2()

CSerialization CSerialization_Create2 ( const CIDRS  argIdrs,
idrs_exception *  pargException 
)

Create the CSerialization instance.

Parameters
argIdrsThe iDRS instance
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ CSerialization_Destroy()

void CSerialization_Destroy ( CSerialization  argCSerialization,
idrs_exception *  pargException 
)

Destroys a CSerialization handle.

Parameters
argCSerializationCSerialization handle to destroy
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ CSerialization_GetFormat()

enum SerializationFormat CSerialization_GetFormat ( const CSerialization  argCSerialization,
idrs_exception *  pargException 
)

Get the serialization format which will be used when saving a page or its content.

Returns
The format to save to
Parameters
argCSerializationCSerialization handle
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ CSerialization_LoadPage()

CPage CSerialization_LoadPage ( const CSerialization  argCSerialization,
const idrs_string  strFileName,
idrs_exception *  pargException 
)

LoadPage loads a page from its serialized format.

Parameters
argCSerializationCSerialization handle
strFileNameThe name of the serialized file.
pargExceptionPointer to exception structure that will be filled if an exception occurs
Returns
The loaded page

◆ CSerialization_LoadPage2()

CPage CSerialization_LoadPage2 ( const CSerialization  argCSerialization,
IByteStream  argStream,
idrs_exception *  pargException 
)

LoadPage loads a page from its serialized format.

Parameters
argCSerializationCSerialization handle
argStreamThe input stream
pargExceptionPointer to exception structure that will be filled if an exception occurs
Returns
The loaded page

◆ CSerialization_LoadPageContent()

CPageContent CSerialization_LoadPageContent ( const CSerialization  argCSerialization,
const idrs_string  strFileName,
idrs_exception *  pargException 
)

LoadPageContent loads page content from the given file.

Parameters
argCSerializationCSerialization handle
strFileNameThe name of the file.
pargExceptionPointer to exception structure that will be filled if an exception occurs
Returns
The page content

◆ CSerialization_LoadPageContent2()

CPageContent CSerialization_LoadPageContent2 ( const CSerialization  argCSerialization,
IByteStream  argStream,
idrs_exception *  pargException 
)

LoadPageContent loads zones from the given stream.

Parameters
argCSerializationCSerialization handle
argStreamThe input stream
pargExceptionPointer to exception structure that will be filled if an exception occurs
Returns
The page content

◆ CSerialization_SavePage()

void CSerialization_SavePage ( const CSerialization  argCSerialization,
const CPage  argPage,
const idrs_string  strFileName,
idrs_exception *  pargException 
)

SavePage saves a page object into its serialized format.

Parameters
argCSerializationCSerialization handle
argPageThe page
strFileNameThe name of the file to save to.
pargExceptionPointer to exception structure that will be filled if an exception occurs
Remarks
For the moment the page's images (source, work, background) are not serialized and should therefore be handled separately by the integrator.

◆ CSerialization_SavePage2()

void CSerialization_SavePage2 ( const CSerialization  argCSerialization,
const CPage  argPage,
IByteStream  argStream,
idrs_exception *  pargException 
)

SavePage saves a page object into its serialized format.

Parameters
argCSerializationCSerialization handle
argPageThe page
argStreamThe output stream to save to.
pargExceptionPointer to exception structure that will be filled if an exception occurs
Remarks
For the moment the page's images (source, work, background) are not serialized and should therefore be handled separately by the integrator.

◆ CSerialization_SavePageContent()

void CSerialization_SavePageContent ( const CSerialization  argCSerialization,
const CPageContent  argPageContent,
const idrs_string  strFileName,
idrs_exception *  pargException 
)

SavePage saves a page's content into its serialized format.

Parameters
argCSerializationCSerialization handle
argPageContentThe source page content
strFileNameThe name of the file.
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ CSerialization_SavePageContent2()

void CSerialization_SavePageContent2 ( const CSerialization  argCSerialization,
const CPageContent  argPageContent,
IByteStream  argStream,
idrs_exception *  pargException 
)

SavePage saves a page's content into its serialized format.

Parameters
argCSerializationCSerialization handle
argPageContentThe source page content
argStreamThe output stream.
pargExceptionPointer to exception structure that will be filled if an exception occurs

◆ CSerialization_SetFormat()

void CSerialization_SetFormat ( CSerialization  argCSerialization,
enum SerializationFormat const  evSerializationVersion,
idrs_exception *  pargException 
)

Set the serialization format which will be used when saving a page or its content.

Remarks
It is recommended to use SerializationFormat::Latest, unless very specific constraints on integrator's side (when several components use different iDRS versions for instance).
Parameters
argCSerializationCSerialization handle
evSerializationVersionThe format to save to
pargExceptionPointer to exception structure that will be filled if an exception occurs