Would it be possible to use AutoMapper in order to fill in an object with details from another object? For example (assuming previous configuration):
var foo = new Foo { PropA = "", PropB = "Foo" };
var bar = new Bar { PropA = "Bar", PropB = "" };
Mapper.Map<Foo, Bar>(foo, bar);
Console.WriteLine(bar.PropB); //Returns "Foo"
Just wondering if anyone has attempted this admittedly odd usage of mapping, which would be more like merging one object's matching data into another object.
Thanks in advance!
Update:
It looks like ValueInjector is a more appropriate too for this situation. There are some great discussions on appropriate uses for AutoMapper vs. ValueInjecter already on StackOverflow.