|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--oracle.toplink.queryframework.DatabaseQuery | +--oracle.toplink.queryframework.ReadQuery | +--oracle.toplink.queryframework.ObjectLevelReadQuery | +--oracle.toplink.queryframework.ReadAllQuery | +--oracle.toplink.queryframework.ReportQuery
Purpose: Query for information about a set of objects instead of the objects themselves. This supports select single attributes, nested attributes, aggregation functions and group bys.
Attribute Types:
retrievePrimaryKeys()
,
If the values are wanted in the result array then they must be added as attributes. For primary keys which are not mapped directly
you can add them as DatabaseFields (see above).
, Serialized FormFields inherited from class oracle.toplink.queryframework.ObjectLevelReadQuery |
CheckCacheByExactPrimaryKey, CheckCacheByPrimaryKey,
CheckCacheOnly, CheckCacheThenDatabase, ConformResultsInUnitOfWork,
DoNotCheckCache, DONT_USE_DISTINCT, exampleObject,
inMemoryQueryIndirectionPolicy, LOCK, LOCK_NOWAIT,
NO_LOCK, queryByExamplePolicy, UNCOMPUTED_DISTINCT,
USE_DISTINCT |
Fields inherited from class oracle.toplink.queryframework.DatabaseQuery |
CascadeAggregateDelete, CascadeAllParts, CascadeDependentParts,
CascadePrivateParts, NoCascading, QUERY_PREPARE |
Fields inherited from interface oracle.toplink.internal.helper.FalseUndefinedTrue |
False, True, Undefined |
Constructor Summary |
ReportQuery(java.lang.Class javaClass,
Expression expression)
|
ReportQuery(java.lang.Class javaClass,
ExpressionBuilder builder)
PUBLIC: The report query is require to be constructor with an expression builder. |
ReportQuery(ExpressionBuilder builder)
PUBLIC: The report query is require to be constructor with an expression builder. |
Method Summary |
Type | Method |
---|---|
void |
addAttribute(java.lang.String itemName)
PUBLIC: Add the attribute from the reference class to be included in the result. |
void |
addAttribute(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the attribute to be included in the result. |
void |
addAverage(java.lang.String itemName)
PUBLIC: Add the average value of the attribute to be included in the result. |
void |
addAverage(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the average value of the attribute to be included in the result. |
void |
addCount()
PUBLIC: Add the count of the size of the result to be included in the result. |
void |
addCount(java.lang.String itemName)
PUBLIC: Add the count of the size of the result to be included in the result. |
void |
addCount(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the count of the size of the result to be included in the result. |
void |
addFunctionItem(java.lang.String itemName,
Expression attributeExpression,
java.lang.String functionName)
ADVANCED: Add the function against the attribute expression to be included in the result. |
void |
addGrouping(Expression expression)
PUBLIC: Add the attribute expression to the group by expressions. |
void |
addGrouping(java.lang.String attributeName)
PUBLIC: Add the attribute to the group by expressions. |
void |
addItem(java.lang.String itemName,
Expression attributeExpression)
ADVANCED: Add the expression value to be included in the result. |
void |
addMaximum(java.lang.String itemName)
PUBLIC: Add the maximum value of the attribute to be included in the result. |
void |
addMaximum(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the maximum value of the attribute to be included in the result. |
void |
addMinimum(java.lang.String itemName)
PUBLIC: Add the minimum value of the attribute to be included in the result. |
void |
addMinimum(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the minimum value of the attribute to be included in the result. |
void |
addStandardDeviation(java.lang.String itemName)
PUBLIC: Add the standard deviation value of the attribute to be included in the result. |
void |
addStandardDeviation(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the standard deviation value of the attribute to be included in the result. |
void |
addSum(java.lang.String itemName)
PUBLIC: Add the sum value of the attribute to be included in the result. |
void |
addSum(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the sum value of the attribute to be included in the result. |
void |
addVariance(java.lang.String itemName)
PUBLIC: Add the variance value of the attribute to be included in the result. |
void |
addVariance(java.lang.String itemName,
Expression attributeExpression)
PUBLIC: Add the variance value of the attribute to be included in the result. |
void |
dontRetrievePrimaryKeys()
PUBLIC: Set if the query results should contain the primary keys or each associated object. |
void |
dontReturnSingleAttribute()
PUBLIC: Don't simplify the result by returning the single attribute. |
void |
dontReturnSingleResult()
PUBLIC: Simplifies the result by only returning the first result. |
void |
dontReturnSingleValue()
PUBLIC: Simplifies the result by only returning a single value. |
boolean |
isReportQuery()
PUBLIC: Return if this is a report query. |
void |
retrievePrimaryKeys()
PUBLIC: Set if the query results should contain the primary keys or each associated object. |
void |
returnSingleAttribute()
PUBLIC: Simplify the result by returning a single attribute. |
void |
returnSingleResult()
PUBLIC: Simplifies the result by only returning the first result. |
void |
returnSingleValue()
PUBLIC: Simplifies the result by only returning a single value. |
void |
setShouldRetrievePrimaryKeys(boolean shouldRetrievePrimaryKeys)
PUBLIC: Set if the query results should contain the primary keys or each associated object. |
void |
setShouldReturnSingleAttribute(boolean newChoice)
PUBLIC: Simplifies the result by only returning the attribute (as opposed to wrapping in a ReportQueryResult). |
void |
setShouldReturnSingleResult(boolean newChoice)
PUBLIC: Simplifies the result by only returning the first result. |
void |
setShouldReturnSingleValue(boolean newChoice)
PUBLIC: Simplifies the result by only returning a single value. |
boolean |
shouldCacheQueryResults()
PUBLIC: Report query results are never cached. |
boolean |
shouldRetrievePrimaryKeys()
PUBLIC: Return if the query results should contain the primary keys or each associated object. |
boolean |
shouldReturnSingleAttribute()
PUBLIC: Answer if we are only returning the attribute (as opposed to wrapping in a ReportQueryResult). |
boolean |
shouldReturnSingleResult()
PUBLIC: Simplifies the result by only returning the first result. |
boolean |
shouldReturnSingleValue()
PUBLIC: Simplifies the result by only returning a single value. |
Methods inherited from class oracle.toplink.queryframework.ReadAllQuery |
addAscendingOrdering, addBatchReadAttribute,
addBatchReadAttribute, addDescendingOrdering,
addOrdering, dontUseCursoredStream, getCursorPageAmount,
getCursorThreshold, isReadAllQuery, remoteExecute,
setContainerPolicy, setCursorPageAmount,
setCursorThreshold, setUsesCursoredStream, useCollectionClass,
useCursoredStream, useCursoredStream, useCursoredStream, useMapClass, useScrollableCursor,
useScrollableCursor |
Methods inherited from class oracle.toplink.queryframework.ReadQuery |
cacheQueryResults, clearQueryResults, doNotCacheQueryResults,
getMaxRows, isReadQuery, setMaxRows,
setShouldCacheQueryResults |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public ReportQuery(java.lang.Class javaClass, Expression expression)
public ReportQuery(java.lang.Class javaClass, ExpressionBuilder builder)
public ReportQuery(ExpressionBuilder builder)
Method Detail |
public void addAttribute(java.lang.String itemName)
public void addAttribute(java.lang.String itemName, Expression attributeExpression)
public void addAverage(java.lang.String itemName)
public void addAverage(java.lang.String itemName, Expression attributeExpression)
public void addCount()
public void addCount(java.lang.String itemName)
public void addCount(java.lang.String itemName, Expression attributeExpression)
public void addFunctionItem(java.lang.String itemName, Expression attributeExpression, java.lang.String functionName)
public void addGrouping(java.lang.String attributeName)
public void addGrouping(Expression expression)
public void addItem(java.lang.String itemName, Expression attributeExpression)
public void addMaximum(java.lang.String itemName)
public void addMaximum(java.lang.String itemName, Expression attributeExpression)
public void addMinimum(java.lang.String itemName)
public void addMinimum(java.lang.String itemName, Expression attributeExpression)
public void addStandardDeviation(java.lang.String itemName)
public void addStandardDeviation(java.lang.String itemName, Expression attributeExpression)
public void addSum(java.lang.String itemName)
public void addSum(java.lang.String itemName, Expression attributeExpression)
public void addVariance(java.lang.String itemName)
public void addVariance(java.lang.String itemName, Expression attributeExpression)
public void dontRetrievePrimaryKeys()
public void dontReturnSingleAttribute()
public void dontReturnSingleResult()
public void dontReturnSingleValue()
public boolean isReportQuery()
isReportQuery
in class DatabaseQuery
public void retrievePrimaryKeys()
public void returnSingleAttribute()
public void returnSingleResult()
public void returnSingleValue()
public void setShouldRetrievePrimaryKeys(boolean shouldRetrievePrimaryKeys)
public void setShouldReturnSingleAttribute(boolean newChoice)
public void setShouldReturnSingleResult(boolean newChoice)
public void setShouldReturnSingleValue(boolean newChoice)
public boolean shouldCacheQueryResults()
shouldCacheQueryResults
in class ReadQuery
public boolean shouldRetrievePrimaryKeys()
public boolean shouldReturnSingleAttribute()
public boolean shouldReturnSingleResult()
public boolean shouldReturnSingleValue()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |