PFileIO Class Reference

Detailed Description

Generic functions to read/write Papillon objects from/to binary files.

You cannot create instances of PFileIO.

Definition at line 30 of file PFileIO.h.

#include <PFileIO.h>

Member Function Documentation

◆ ReadFromFile()

template<class T >
static PResult PFileIO::ReadFromFile ( const PString filename,
T &  object,
ESerialisationFormat  format = E_BINARY_FORMAT 
)
inlinestatic

Reads a Papillon object from a binary file.

Returns PResult::C_OK if success, another result otherwise.

Definition at line 38 of file PFileIO.h.

◆ WriteToFile()

template<class T >
static PResult PFileIO::WriteToFile ( const PString filename,
const T &  object,
ESerialisationFormat  format = E_BINARY_FORMAT 
)
inlinestatic

Writes a Papillon object to file as binary data.

Returns PResult::C_OK if success, another result otherwise.

Definition at line 50 of file PFileIO.h.