|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.datanucleus.query.evaluator.JavaQueryEvaluator
public abstract class JavaQueryEvaluator
Class to evaluate a Java "string-based" query in whole or part. Takes in a list of instances and applies the required restrictions to the input giving a final result. Typically extended for JDOQL, JPQL, SQL specifics.
| Field Summary | |
|---|---|
protected java.lang.String |
candidateAlias
|
protected java.util.Collection |
candidates
Candidates objects to evaluate. |
protected ClassLoaderResolver |
clr
|
protected QueryCompilation |
compilation
Compilation of the underlying query, that we are evaluating. |
protected InMemoryExpressionEvaluator |
evaluator
The evaluator. |
protected java.lang.String |
language
|
protected static Localiser |
LOCALISER
Localisation utility for output messages |
protected java.util.Map |
parameterValues
Map of input parameter values, keyed by the parameter name. |
protected Query |
query
Underlying "string-based" query. |
static java.lang.String |
RESULTS_SET
Name under which any set of results are stored in the state map. |
protected java.util.Map<java.lang.String,java.lang.Object> |
state
Map of state symbols for the query evaluation. |
| Constructor Summary | |
|---|---|
JavaQueryEvaluator(java.lang.String language,
Query query,
QueryCompilation compilation,
java.util.Map parameterValues,
ClassLoaderResolver clr,
java.util.Collection candidates)
Constructor for the evaluator of a query in the specified language. |
|
| Method Summary | |
|---|---|
protected abstract java.util.Collection |
evaluateSubquery(Query subquery,
java.util.Collection candidates,
QueryCompilation compilation)
Method to evaluate a subquery of the query being evaluated. |
java.util.Collection |
execute(boolean applyFilter,
boolean applyOrdering,
boolean applyResult,
boolean applyResultClass,
boolean applyRange)
Method to perform the evaluation, applying the query restrictions that are required. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final Localiser LOCALISER
public static final java.lang.String RESULTS_SET
protected final java.lang.String language
protected java.lang.String candidateAlias
protected java.util.Collection candidates
protected Query query
protected QueryCompilation compilation
protected java.util.Map parameterValues
protected InMemoryExpressionEvaluator evaluator
protected java.util.Map<java.lang.String,java.lang.Object> state
protected ClassLoaderResolver clr
| Constructor Detail |
|---|
public JavaQueryEvaluator(java.lang.String language,
Query query,
QueryCompilation compilation,
java.util.Map parameterValues,
ClassLoaderResolver clr,
java.util.Collection candidates)
language - Name of the languagequery - The underlying querycompilation - Query compilationparameterValues - Input parameter valuesclr - ClassLoader resolvercandidates - Candidate objects| Method Detail |
|---|
protected abstract java.util.Collection evaluateSubquery(Query subquery,
java.util.Collection candidates,
QueryCompilation compilation)
subquery - The subquerycandidates - The candidates for the subquerycompilation - The subquery compilation
public java.util.Collection execute(boolean applyFilter,
boolean applyOrdering,
boolean applyResult,
boolean applyResultClass,
boolean applyRange)
applyFilter - Whether to apply any filter constraints on the resultsapplyOrdering - Whether to apply any order constraints on the resultsapplyResult - Whether to apply any result/grouping/having on the resultsapplyResultClass - Whether to apply any resultClass constraint on the resultsapplyRange - Whether to apply any range constraint on the results
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||