Using AutoMapper for MVVM implementations
Being Clean Code Developers, whenever we start developing a new application, we try to improve our code quality, right? As a part of that, we librarify what can be librarified and use 3rd Party and Open Source assemblies wherever possible so we can concentrate on the really dirty work. OK, here's one thing Stefan Lieser brought to my attention in the course a Google Group discussion. It's called AutoMapper , and as the name gives away is a great deal of help when you have to map instances of Type A to instances of type B (very simply put, really). Sounds rather boring at first glance, but me and my buddy Maik decided we'd take a look at it for our nhibernate based MVVM implementations, in which (up to now) the viewmodels were wrappers / proxies for the models. Apart from that, it does great Conversions from one list type to another, which was a numb piece of loop-through-source-store-in-destination. The Gloria : Stickiness of memory addresses Having worked with NHibernate,