|
From: <tri...@tr...> - 2004-02-05 17:37:37
|
I don't like the IXxxxx naming either, and it is inconsistent with other Spring interfaces/implementations. I vote for a name change of the interface classes to either JdbcInterface/HibernateInterface/SqlMapInterface or as you suggested JdbcOperations/HibernateOperations/SqlMapOperations. Thomas Quoting "jürgen höller [werk3AT]" <jue...@we...>: > Everybody, > > Due to a recent request, I've just extracted IHibernateTemplate and > ISqlMapTemplate interfaces, analogous to IJdbcTemplate that Rod introduced a > while ago. They are intended to ease mocking for unit-testing DAOs, for those > who want to mock at this level. For typical DAO implementations, the standard > template classes are good enough, allowing for mocks of the underlying > persistence tool and live tests against a database. > > However, I wonder about the naming. We don't have the I* pattern anywhere > else in the framework; on the other hand, we need to keep the old template > names for compatibility (and some templates don't lend themselves for such an > interface, like JdoTemplate). IHibernateTemplate etc doesn't worry me, but > maybe a different name like HibernateOperations would be better? Essentially, > those interfaces specify a set of data access operations for a particular > persistence tool. > > The naming isn't too important, though, as it will not be the main API that > people will work with; the template classes will be. We'll just let the > templates implement those operation interfaces to allow for mocking them if > desired. BTW, iBATIS SQL Maps is all based on concrete classes rather than > interfaces, not allowing to mock the persistence tool itself. > > Juergen > > > > ------------------------------------------------------- > The SF.Net email is sponsored by EclipseCon 2004 > Premiere Conference on Open Tools Development and Integration > See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. > http://www.eclipsecon.org/osdn > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer > |