Posted on October 7th, 2009
brandon
In my efforts to build web applications using domain model programming I’ve encountered some interesting technical hurdles for keeping my implementation details away from my models. The most problematic issue that has come up time and time again has been that of using paginators. It’s very difficult to keep your paginator class in the dark about database implementation details and have it be able to handle complex use cases. Over the last few months I have slowly evolved a sophisticated way to describe a complex sql query using nothing more than an associative array which can be passed to a clueless paginator which talks to the database through a predefined interface to a model gateway. Yeah the mad scientist is me because that’s how I felt when I looked back on the pure genius of this method.
Read Entire Article