Skip to main content

AutoMapping

Customize ServiceStack AutoMapping Behavior

Assembly: ServiceStack.Text.dll
View Source
Declaration
public static class AutoMapping

Methods

RegisterConverter<From, To>(Func<From, To>)

Register Type to Type AutoMapping converter

View Source
Declaration
public static void RegisterConverter<From, To>(Func<From, To> converter)
Parameters
TypeName
System.Func<<From>,<To>>converter
Type Parameters
  • From
  • To

IgnoreMapping<From, To>()

Ignore Type to Type Mapping (including collections containing them)

View Source
Declaration
public static void IgnoreMapping<From, To>()
Type Parameters
  • From
  • To

IgnoreMapping(Type, Type)

Ignore Type to Type Mapping (including collections containing them)

View Source
Declaration
public static void IgnoreMapping(Type fromType, Type toType)
Parameters
TypeName
System.TypefromType
System.TypetoType

RegisterPopulator<Target, Source>(Action<Target, Source>)

View Source
Declaration
public static void RegisterPopulator<Target, Source>(Action<Target, Source> populator)
Parameters
TypeName
System.Action<<Target>,<Source>>populator
Type Parameters
  • Target
  • Source