Many time we need to map objects between UI/Domain or Service/Domain layers. Mapping the objects between them is very hectic. So, are there any simplest mechanism by which I can map two objects? Is there is. There is a AutoMapper class which you can use to map between two objects. This also provides option to do a custom mapping. Let's begin with it and learn about it today. What is AutoMapper? AutoMapper is a mapper between two objects. It maps two different entities by transforming an input object of one type to an output object of another type. It is very tough job to map two different entities and sometime it is even more hectic when it comes to testing. It can be anywhere in the application but in general it happens in UI/Domain or Service/Domain layers. AutoMapper resolves that tough job by mapping it with proper convention and removes all the dirty works. Not only that, you can also customize the mapping with proper parameters. ...


I guess you came to this post by searching similar kind of issues in any of the search engine and hope that this resolved your problem. If you find this tips useful, just drop a line below and share the link to others and who knows they might find it useful too.

Stay tuned to my blogtwitter or facebook to read more articles, tutorials, news, tips & tricks on various technology fields. Also Subscribe to our Newsletter with your Email ID to keep you updated on latest posts. We will send newsletter to your registered email address. We will not share your email address to anybody as we respect privacy.


This article is related to

C#,.NET,Architect,Intermediate,VS2010,.Net,Articles,Computer Tutorials,AutoMapper