//create a new target and map source on it public static TTarget Map <TSource, TTarget>(TSource source) { var target = (TTarget)Creator.Create(typeof(TTarget)); return(MapperFactory.GetMapper <TSource, TTarget>().Map(source, target)); }
public void End() { MapperFactory.ClearMappers(); }
//map source to an existing target public static TTarget Map <TSource, TTarget>(TSource source, TTarget target) { target = MapperFactory.GetMapper <TSource, TTarget>().Map(source, target); return(target); }