November Happy Hour will be moved to Thursday December 5th.

Interface IObjectSerializerFactory

Factory that is used to register and get serializers for a given content type.

Namespace: EPiServer.Framework.Serialization
Assembly: EPiServer.Framework.dll
Version: 9.12.2
Syntax
public interface IObjectSerializerFactory

Methods

GetSerializer(String)

Gets the serializer for the given content type.

Declaration
IObjectSerializer GetSerializer(string contentType)
Parameters
Type Name Description
System.String contentType

The content type.

Returns
Type Description
IObjectSerializer

An IObjectSerializer for the given content type or null if no serializer is registered for the content type.

RegisterSerializer(String, ServiceAccessor<IObjectSerializer>)

Registers an IObjectSerializer for a given content type.

Declaration
void RegisterSerializer(string contentType, ServiceAccessor<IObjectSerializer> accessor)
Parameters
Type Name Description
System.String contentType

The content type to handle.

ServiceAccessor<IObjectSerializer> accessor

The accessor delegate.

Extension Methods