AgateLib.Serialization.Xle.XleSerializer Class Reference

Class used to serialize data to a compact XML format. More...

List of all members.

Public Member Functions

 XleSerializer (Type objectType)
 Constructs the XleSerializer. Pass in the type of the object which is the root of the object graph which needs to be serialized. This type must implement the IXleSerializable interface.
void Serialize (Stream outStream, IXleSerializable objectGraph)
 Serializes an object which implements IXleSerializable to the specified stream.
object Deserialize (Stream inStream)
 Deserializes an object from the XML data in the specified stream.
Deserialize< T > (Stream inStream)
 Deserializes an object from the XML data in the specified stream with the specified type.

Properties

ITypeBinder Binder [get, set]
 An object which implements the AgateLib.Serialization.Xle.ITypeBinder interface. This object is used to convert strings to System.Type objects. The default value for this property is an object of type AgateLib.Serialization.Xle.TypeBinder, but it may be replaced for custom type binding.


Detailed Description

Class used to serialize data to a compact XML format.


Constructor & Destructor Documentation

AgateLib.Serialization.Xle.XleSerializer.XleSerializer ( Type  objectType  ) 

Constructs the XleSerializer. Pass in the type of the object which is the root of the object graph which needs to be serialized. This type must implement the IXleSerializable interface.

Parameters:
objectType The type of the object to serialize.


Member Function Documentation

object AgateLib.Serialization.Xle.XleSerializer.Deserialize ( Stream  inStream  ) 

Deserializes an object from the XML data in the specified stream.

Parameters:
inStream The stream containing the XML data.
Returns:
The deserialized object.

T AgateLib.Serialization.Xle.XleSerializer.Deserialize< T > ( Stream  inStream  ) 

Deserializes an object from the XML data in the specified stream with the specified type.

Template Parameters:
T Type to cast the return value to.
Parameters:
inStream The stream containing the XML data.
Returns:
The deserialized object.

void AgateLib.Serialization.Xle.XleSerializer.Serialize ( Stream  outStream,
IXleSerializable  objectGraph 
)

Serializes an object which implements IXleSerializable to the specified stream.

Parameters:
outStream The stream to write the XML data to.
objectGraph The object to serialize.


Property Documentation

ITypeBinder AgateLib.Serialization.Xle.XleSerializer.Binder [get, set]

An object which implements the AgateLib.Serialization.Xle.ITypeBinder interface. This object is used to convert strings to System.Type objects. The default value for this property is an object of type AgateLib.Serialization.Xle.TypeBinder, but it may be replaced for custom type binding.


The documentation for this class was generated from the following file:
AgateLib
Awesome Game and Tool Engine Library
SourceForge.net Logo