Class FallbackSerializationExtension
Configures a serializer so that if an exception occcurs during selection of a serializer for a given type, a provided fallback serializer is selected instead. By default the provided fallback serializer does nothing for serializer and returns a null instance for deserialization.
Inheritance
System.Object
FallbackSerializationExtension
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ExtendedXmlSerializer.ExtensionModel
Assembly: ExtendedXmlSerializer.dll
Syntax
public class FallbackSerializationExtension : ISerializerExtension, IAlteration<IServiceRepository>, IParameterizedSource<IServiceRepository, IServiceRepository>, ICommand<IServices>
Constructors
FallbackSerializationExtension(FallbackSerializationExtension.IFallbackSerializer)
Creates a new instance.
Declaration
public FallbackSerializationExtension(FallbackSerializationExtension.IFallbackSerializer fallback)
Parameters
FallbackSerializationExtension.IFallbackSerializer
fallback
The fallback serializer to use in case an exception is thrown during serialzer selection.. |
Properties
Default
The default instance. By default the provided fallback serializer does nothing for serializer and returns a null instance for deserialization.
Declaration
public static FallbackSerializationExtension Default { get; }
Property Value
FallbackSerializationExtension
|
Methods
Get(IServiceRepository)
Performs the selection.
Declaration
public IServiceRepository Get(IServiceRepository parameter)
Parameters
IServiceRepository
parameter
|
Returns
IServiceRepository
A value of the return type. |
Implements
Explicit Interface Implementations
ICommand<IServices>.Execute(IServices)
Declaration
void ICommand<IServices>.Execute(IServices parameter)
Parameters
IServices
parameter
|