Can Automapper map values from a NameValueCollection
onto an object, where target.Foo
receives the value stored in the collection under the "Foo" key?
I have a business object that stores some data in named properties and other data in a property bag. Different views make different assumptions about the data in the property bag, which I capture in page-specific view models. I want to use AutoMapper to map both the "inherent" attributes (the ones that always exist) as well as the "dynamic" attributes (the ones that vary per view and may or may not exist).