org.jaffa.beans.moulding.data.criteria
Class CriteriaDAO

java.lang.Object
  extended byorg.jaffa.beans.moulding.data.criteria.CriteriaDAO

public abstract class CriteriaDAO
extends Object

The base class for all Criteria Data Access Objects.

This provides some common properties that are used by all Criteria objects. This includes such things as Max Rows to return and what fields/objects should be included in the resultant domain object graphs.

Version:
1.0
Author:
PaulE

Constructor Summary
CriteriaDAO()
          Creates a new instance of CriteriaDAO
 
Method Summary
 Integer getObjectLimit()
          Getter for property objectLimit.
 String[] getResultGraphRules()
          Getter for property resultGraphRules.
abstract  Criteria returnQueryClause()
          Return the real retrieve clause that will be executed for this query.
 void setObjectLimit(Integer objectLimit)
          Setter for property objectLimit.
 void setResultGraphRules(String[] resultGraphRules)
          Setter for property resultGraphRules.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CriteriaDAO

public CriteriaDAO()
Creates a new instance of CriteriaDAO

Method Detail

getObjectLimit

public Integer getObjectLimit()
Getter for property objectLimit.

Returns:
Value of property objectLimit.

setObjectLimit

public void setObjectLimit(Integer objectLimit)
Setter for property objectLimit.

This is the maximum root level object to be returned by the query. This is implemented as a safe guard to prevent 'runaway' queries that could try and bring back millions of rows.

Defaults to 25 objects any number below 1 implies ALL objects.

Parameters:
objectLimit - New value of property objectLimit.

returnQueryClause

public abstract Criteria returnQueryClause()
Return the real retrieve clause that will be executed for this query.

THIS MUST BE OVERRIDDEN BY THE SUPERCLASS

Returns:
return the generated clause

getResultGraphRules

public String[] getResultGraphRules()
Getter for property resultGraphRules.

Returns:
Value of property resultGraphRules.

setResultGraphRules

public void setResultGraphRules(String[] resultGraphRules)
Setter for property resultGraphRules.

These rules control what fields and related objects should be included in the returned Domain Object Graph. By default only the top level object, and skeleton related foreign objects are included.

See How to control what is returned in a domain object graph for examples of how to use this to control what is returned in the output graph.

Parameters:
resultGraphRules - New value of property resultGraphRules.


Copyright © 2002-2004 JAFFA Project.