#include <CeylanSerializable.h>
Public Member Functions | |
Serializable () | |
Do-nothing constructor. | |
virtual | ~Serializable () throw () |
Do-nothing virtual destructor. | |
virtual void | saveTo (System::OutputStream &output) const =0 |
Saves the instance state to specified stream. | |
virtual void | loadFrom (System::InputStream &input)=0 |
Loads a new instance state from specified stream. | |
Private Member Functions | |
Serializable (const Serializable &source) | |
Copy constructor made private to ensure that it will be never called. | |
Serializable & | operator= (const Serializable &source) |
Assignment operator made private to ensure that it will be never called. |
Serializing objects is converting them to a stream of bytes. It is useful to send them accross the network, or to store them in files for example.
Definition at line 79 of file CeylanSerializable.h.
Ceylan::Serializable::Serializable | ( | ) | [inline] |
virtual Ceylan::Serializable::~Serializable | ( | ) | throw () [inline, virtual] |
Ceylan::Serializable::Serializable | ( | const Serializable & | source | ) | [private] |
Copy constructor made private to ensure that it will be never called.
The compiler should complain whenever this undefined constructor is called, implicitly or not.
virtual void Ceylan::Serializable::loadFrom | ( | System::InputStream & | input | ) | [pure virtual] |
Loads a new instance state from specified stream.
input | the input stream from which the state will be read. |
SerializationException | if the operation failed. |
Implemented in Ceylan::XML::XMLMarkup, and Ceylan::XML::XMLText.
Serializable& Ceylan::Serializable::operator= | ( | const Serializable & | source | ) | [private] |
Assignment operator made private to ensure that it will be never called.
The compiler should complain whenever this undefined operator is called, implicitly or not.
virtual void Ceylan::Serializable::saveTo | ( | System::OutputStream & | output | ) | const [pure virtual] |
Saves the instance state to specified stream.
output | the output stream to which the state will be written. |
SerializationException | if the operation failed. |
Implemented in Ceylan::XML::XMLElement, Ceylan::XML::XMLMarkup, and Ceylan::XML::XMLText.