/// <summary> /// Registers mapping from TInterface to instance. /// The mapping is valid for this model object and child objects. /// </summary> public static void RegisterDefault <TInterface>(this ModelMapper mapper, TInterface instance) { mapper.RegisterDefault(typeof(TInterface), instance); }
/// <summary> /// Registers mapping for TFor from TFrom to TTo. /// The mapping is only valid for TFor. /// </summary> public static void RegisterMapping <TFor, TFrom, TTo>(this ModelMapper mapper) { mapper.RegisterMapping(typeof(TFor), typeof(TFrom), typeof(TTo)); }
public ModelMapper(object model, ModelMapper parentMapper) : this(model, parentMapper.TypeMappings.Container, parentMapper.Registry) { }