I had some time before Christmas break to do a quick first pass at
taking all references to Criteria and Criterion in the Runtime classes
to use a matching Interface class (boringly named CriteriaInterface
These interfaces are not based on just extracting all methods from
current classes. Instead they have been limited to the methods
that are currently by the Runtime classes that use Criteria (e.g.
BasePeer, SQLBuilder, and the like).
The thought here is to allow for new Criteria and Criterion classes
to be added without changing the existing ones. IMHO, a good
way to start looking at supporting things like functions and other
things talked about without adding even more methods to the
This work is at a stage that all dev's interested in Torque should get
a peek at it and make comments. So, I'm attaching the first pass at
the interfaces to this.
Some issues that I know still need to be done:
The interface probably should be morphed into a clear design rather
than a "it's there because someone used it in a class".
Templates generate Criteria references.
Template generated classes create Criteria classes in several places.
There will need to be a Criteria "factory" methodolgy worked out to
Greg Monroe <Monroe@DukeCE.com> (919)680-5050
C&IS Solutions Team Lead
Duke Corporate Education, Inc.
333 Liggett St.
Durham, NC 27701
Duke CE Privacy Statement