C# Class Bamboo.Prevalence.Serialization.AutoVersionMigrationSurrogate

Serialization surrogate and selector that allows any new version of a serialiazable class to be loaded from an outdated serialized representation.
Any new class fields not present in the serialization data will be left uninitialized. Removed fields are ignored (no exceptions).
Inheritance: ISerializationSurrogate, ISurrogateSelector
Show file Open project: bamboo/Bamboo.Prevalence Class Usage Examples

Public Methods

Method Description
AutoVersionMigrationSurrogate ( Assembly assemblyToMigrate ) : System

Create a surrogate that will be used to serialize/deserialize all the types in the assembly specified.

Private Methods

Method Description
FindField ( Type t, string name ) : FieldInfo
ISurrogateSelector ( System type, System context, System &selector ) : System.Runtime.Serialization.ISerializationSurrogate
ISurrogateSelector ( ) : System.Runtime.Serialization.ISurrogateSelector
ISurrogateSelector ( System selector ) : void
System ( object obj, System info, System context, System selector ) : object
System ( object obj, System info, System context ) : void

Method Details

AutoVersionMigrationSurrogate() public method

Create a surrogate that will be used to serialize/deserialize all the types in the assembly specified.
public AutoVersionMigrationSurrogate ( Assembly assemblyToMigrate ) : System
assemblyToMigrate System.Reflection.Assembly
return System