In my case, it's a bit less code: Mapper interface: List<MyObject> getByCompoundKey(@Param("id1") Integer id1, @Param("id2") Integer id2);
versus Method in some class: @SupressWarnings("unchecked") List<MyObject> getByCompoundKey(Integer id2, Integer id2) { Map parms = new HashMap(); parms.put("id1", id1); parms.put("id2", id2); return sqlSession.selectList("foo.Bar.getById", parms); } YMMV. Jeff Butler On Wed, Feb 17, 2010 at 2:36 PM, Rick R <ric...@gmail.com> wrote: > On Wed, Feb 17, 2010 at 2:51 PM, Jeff Butler <jeffgbut...@gmail.com> wrote: >> >> Using a mapper interface means you have a bit less code to write > > How is it less code?, that's my whole point in dropping it since I think it > adds more code (for in our case seemingly little gain.) All my sql is in xml > and for every mapper xml statement I create I have to go over and add a > Mapper interface method. It's just one more piece of code that needs > attention. --------------------------------------------------------------------- To unsubscribe, e-mail: user-java-unsubscr...@ibatis.apache.org For additional commands, e-mail: user-java-h...@ibatis.apache.org