Thursday, 13 August 2009

AutoMapper

Disclaimer - I have been using AutoMapper only for two weeks, so i might be wrong here

So, This tool avoid lot of pain from writing mapping codes. But being said that it is not a mature tool and will be a pain in butt incase of even medium level hierarchies.

With the verion 0.3.1(from Code plex),

1. You can't use abstract relation ship - though r116(latest as of now) solves this problem. What i mean here is

If you map 'Dog' to 'Dog' with a code like .Map(new Source.Dog()), it fails.

But if Source.Animal is interface, then it works. What crap?

2. Not perfect with collections(r116)

But being said that, if you have classes with simple/no relationship, this is a great tool.

1 comment:

Jimmy Bogard said...

Hi Suresh,

If you have some specific scenarios that are missing, I'd love to see some code for them! Perhaps you could post them on the message board?