I want to create new fields and replace others when I map objects in C #, as I show below
public class one
{
public int a {get; set;}
public int b {get; set;}
public int c {get; set;}
}
public class two
{
public int sum {get; set;} //sum = a + b +c ;
}
Mapper.Initialize(cfg =>
{
cfg.CreateMap<one, two>();//?????mapping sum = a+b+c;
});
Please, any idea?