资 源 简 介
Cogs is a set of utilities around the Cog interface which allow easy construction of complex SQL statements, and easy assembly of pojos from the returned ResultSets. It is a lightweight addition that allows clean, modular code that helps separate SQL from Java. An implementation of a Cog is a helper class which an automatically make basic queries (INSERT, UPDATE, etc), can be combined with other cogs to easily generate moderately complex queries (such as selecting an object and some dependents subject to a WHERE condition that depends on JOINs), and can be used in a template/context pattern to make complex queries (including subqueries, etc). A Cog also contains the information to assemble Model objects (and its foreign keys/dependents) from ResultSets, with no casting required.
The Cogs project is for people who are tired of the boilerplate code and messy, hard-to-reuse SQL of JDBC, but who don"t w