Show / Hide Table of Contents

Class TypeSerializerComposerRegistrationContext<T>

Provides a context for registering content composers for a particular type.

Inheritance
System.Object
TypeSerializerComposerRegistrationContext<T>
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.Configuration
Assembly: ExtendedXmlSerializer.dll
Syntax
public sealed class TypeSerializerComposerRegistrationContext<T>
Type Parameters
T

The type under configuration.

Constructors

TypeSerializerComposerRegistrationContext(ITypeConfiguration<T>)

Creates a new instance.

Declaration
public TypeSerializerComposerRegistrationContext(ITypeConfiguration<T> configuration)
Parameters
ITypeConfiguration<T> configuration

Methods

ByCalling(Func<ISerializer, ISerializer>)

Used to alter a serializer whenever one is created for a specific type. This allows the scenario of decorating a serializer to override or monitor serialization and/or deserialization. This override accepts a generalized serializer delegate.

Declaration
public ITypeConfiguration<T> ByCalling(Func<ISerializer, ISerializer> compose)
Parameters
System.Func<ISerializer, ISerializer> compose

The delegate that defines how to create a content serializer.

Returns
ITypeConfiguration<T>

The configured type configuration.

See Also
https://github.com/ExtendedXmlSerializer/home/issues/264#issuecomment-531491807

ByCalling(Func<ISerializer<T>, ISerializer<T>>)

Used to alter a serializer whenever one is created for a specific type. This allows the scenario of decorating a serializer to override or monitor serialization and/or deserialization.

Declaration
public ITypeConfiguration<T> ByCalling(Func<ISerializer<T>, ISerializer<T>> compose)
Parameters
System.Func<ISerializer<T>, ISerializer<T>> compose

The delegate that defines how to create a content serializer.

Returns
ITypeConfiguration<T>

The configured type configuration.

See Also
https://github.com/ExtendedXmlSerializer/home/issues/264#issuecomment-531491807

None()

Clears any registered content serializer composers for the type under configuration.

Declaration
public ITypeConfiguration<T> None()
Returns
ITypeConfiguration<T>

The configured type configuration.

See Also
https://github.com/ExtendedXmlSerializer/home/issues/264#issuecomment-531491807

Of(Type)

Registers a content serializer composer of the specified type.

Declaration
public ITypeConfiguration<T> Of(Type composerType)
Parameters
System.Type composerType

The type that implements ISerializerComposer of the content composer to register.

Returns
ITypeConfiguration<T>

The configured type configuration.

See Also
https://github.com/ExtendedXmlSerializer/home/issues/264#issuecomment-531491807

Of<TComposer>()

Registers a content serializer composer of the specified type.

Declaration
public ITypeConfiguration<T> Of<TComposer>()
    where TComposer : ISerializerComposer<T>
Returns
ITypeConfiguration<T>

The configured type configuration.

Type Parameters
TComposer

The type of the content composer to register.

See Also
https://github.com/ExtendedXmlSerializer/home/issues/264#issuecomment-531491807

Using(ISerializerComposer)

Used to alter a serializer whenever one is created for a specific type. This allows the scenario of decorating a serializer to override or monitor serialization and/or deserialization. This override accepts an ISerializerComposer that performs the alteration on the created serializer.

Declaration
public ITypeConfiguration<T> Using(ISerializerComposer composer)
Parameters
ISerializerComposer composer

The serializer composer to register.

Returns
ITypeConfiguration<T>

The configured type configuration.

See Also
https://github.com/ExtendedXmlSerializer/home/issues/264#issuecomment-531491807

Extension Methods

ExtensionMethods.Return<T, TOut>(T, TOut)
ExtensionMethods.To<T>(Object)
ExtensionMethods.AsValid<T>(Object, String)
ExtensionMethodsForAttachedProperties.Get<TType, TValue>(TType, Property<TType, TValue>)
ExtensionMethodsForAttachedProperties.Set<TType, TValue>(TType, Property<TType, TValue>, TValue)
ExtensionMethodsForCoreSources.If<TParameter, TResult>(TResult, ISpecification<TParameter>)
ExtensionMethodsForCoreSources.Let<TSpecification, TInstance>(TInstance, ISpecification<TSpecification>, TInstance)
Back to top Generated by DocFX