| java.lang.Object org.jpox.store.query.QueryCompiler
QueryCompiler | public class QueryCompiler (Code) | | Base definition of a query compiler for a query language.
Should be extended to compile details of individual query languages.
version: $Revision$ |
COMPILE_EXECUTION | final public static int COMPILE_EXECUTION(Code) | | |
COMPILE_EXPLICIT_PARAMETERS | final public static int COMPILE_EXPLICIT_PARAMETERS(Code) | | |
COMPILE_EXPLICIT_VARIABLES | final public static int COMPILE_EXPLICIT_VARIABLES(Code) | | |
COMPILE_SYNTAX | final public static int COMPILE_SYNTAX(Code) | | |
LOCALISER | final protected static Localiser LOCALISER(Code) | | Localiser for messages.
|
candidateAlias | protected String candidateAlias(Code) | | Alias for the candidate class.
|
candidateClass | protected Class candidateClass(Code) | | Candidate class for the query. May be updated during the compilation.
|
executionCompile | protected boolean executionCompile(Code) | | Flag for whether the current compile is for execution (using param values).
|
imports | protected Imports imports(Code) | | Imports to use for the resolution of classes.
|
language | protected String language(Code) | | Language of this query (e.g JDOQL, JPQL).
|
parameterNames | protected List parameterNames(Code) | | The parameter names.
|
parameterTypesByName | protected Map parameterTypesByName(Code) | | Look-up for the parameter types, keyed by the name.
|
parameters | protected Map parameters(Code) | | Map of parameter values, keyed by their name.
|
query | protected Query query(Code) | | The query being compiled.
|
variableNames | protected List variableNames(Code) | | List of variable names.
|
variableTypesByName | protected Map variableTypesByName(Code) | | Look-up for the variables types, keyed by the name.
|
QueryCompiler | public QueryCompiler(Query query, Imports imports, Map parameters)(Code) | | Constructor for a compiler of java queries.
Parameters: query - The query to compile Parameters: imports - The imports to use Parameters: parameters - Any parameters |
close | public void close()(Code) | | Method to close the Compiler.
|
compile | public Object compile(int type)(Code) | | Method to compile the query.
Parameters: type - Type of compilation. This compiler only supports explicit parameters, explicit variables the compilation artifact (if any) |
compileExplicitParameters | protected void compileExplicitParameters()(Code) | | Method to compile all parameters declared for this query.
Takes the input "parameters" and populates "parameterNames", "parameterTypesByName" for convenience.
|
compileExplicitVariables | protected void compileExplicitVariables()(Code) | | Method to compile all variables declared for this query.
Takes the input "variables" and populates "variableNames", "variableTypesByName" for convenience.
|
getCandidateAlias | public String getCandidateAlias()(Code) | | Accessor for the candidate alias.
Candidate alias |
getCandidateClass | public Class getCandidateClass()(Code) | | Accessor for the candidate class. May have been updated during the compile process.
Candidate class |
getParameterNames | public String[] getParameterNames()(Code) | | Accessor for the (explicit) parameter names.
Parameter names |
getParameterTypesByName | public Map getParameterTypesByName()(Code) | | Accessor for the parameter types keyed by the parameter name.
Generated during compile of explicit parameters.
Map of parameter type keyed by name |
|
|