Wed - 16 Dec
Written by Alexander Romanenko
Data mapper is a must haveObject Relational Model pattern in any application. In simpler terms, it is a translation adapter between your persistent database storage and the objects in your application that you can actually work with. Although for medium or more complex projects you should avoid writing your own datamappers and rely on more field proven and testing ORMs, such as doctrine, you should have a good understanding of what is really going on before jumping to full ORMs and risking not knowing how to take advantage of them. And of course for smaller projects something like doctrine can be an overkill and putting together a small set DataMapper classes is perfect.
Read more...