Is possible with Automapper to map a flat object to complex object graph?
Mapper.CreateMap<PersonDto,Person>()
Map PersonDto.BirthCertificateFatherName to Person.BirthCertificate.FatherName
Is possible with Automapper to map a flat object to complex object graph?
Mapper.CreateMap<PersonDto,Person>()
Map PersonDto.BirthCertificateFatherName to Person.BirthCertificate.FatherName
No it can't, it does it the other way
Person.BirthCertificate.FatherName to PersonDto.BirthCertificateFatherName
UPDATE: ValueInjecter can do this:
//unflattening
person.InjectFrom<UnflatLoopValueInjection>(personDto);
//flatenning
personDto.InjectFrom<FlatLoopValueInjection>(person);