|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.chemistry.opencmis.server.support.query.QueryObject
public class QueryObject
QueryObject is a class used to encapsulate a CMIS query. It is created from an ANTLR parser on an incoming query string. During parsing various informations are collected and stored in objects suitable for evaluating the query (like selected properties, effected types and order statements. A query evaluator can use this information to perform the query and build the result.
Nested Class Summary | |
---|---|
static class |
QueryObject.JoinSpec
|
class |
QueryObject.SortSpec
|
Field Summary | |
---|---|
protected Map<String,CmisSelector> |
colOrFuncAlias
|
protected Map<Integer,CmisSelector> |
columnReferences
|
protected String |
from
main from alias name |
protected Map<String,String> |
froms
map from alias name to type query name |
protected List<CmisSelector> |
joinReferences
|
protected List<QueryObject.JoinSpec> |
joinSpecs
|
protected List<CmisSelector> |
selectReferences
|
protected List<QueryObject.SortSpec> |
sortSpecs
|
protected TypeManager |
typeMgr
|
protected Map<Integer,String> |
typeReferences
|
protected List<CmisSelector> |
whereReferences
|
Constructor Summary | |
---|---|
QueryObject()
|
|
QueryObject(TypeManager tm)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected TypeManager typeMgr
protected final List<CmisSelector> selectReferences
protected final List<CmisSelector> whereReferences
protected final List<CmisSelector> joinReferences
protected final Map<String,CmisSelector> colOrFuncAlias
protected final Map<String,String> froms
protected String from
protected final List<QueryObject.JoinSpec> joinSpecs
protected final Map<Integer,CmisSelector> columnReferences
protected final Map<Integer,String> typeReferences
protected final List<QueryObject.SortSpec> sortSpecs
Constructor Detail |
---|
public QueryObject()
public QueryObject(TypeManager tm)
Method Detail |
---|
public Map<Integer,CmisSelector> getColumnReferences()
public CmisSelector getColumnReference(Integer token)
public String getTypeReference(Integer token)
public String getErrorMessage()
public List<CmisSelector> getSelectReferences()
public void addSelectReference(org.antlr.runtime.tree.Tree node, CmisSelector selRef)
public void addAlias(String aliasName, CmisSelector aliasRef)
public CmisSelector getSelectAlias(String aliasName)
public String addType(String aliasName, String typeQueryName)
public String getMainTypeAlias()
public Map<String,String> getTypes()
public String getTypeQueryName(String qualifier)
public TypeDefinition getTypeDefinitionFromQueryName(String queryName)
public TypeDefinition getParentType(TypeDefinition td)
public TypeDefinition getParentType(String typeId)
public TypeDefinition getMainFromName()
public Map<String,String> getRequestedPropertiesByAlias()
@Deprecated public Map<String,String> getRequestedProperties()
@Deprecated public Map<String,String> getRequestedFuncs()
public Map<String,String> getRequestedFuncsByAlias()
public void addJoinReference(org.antlr.runtime.tree.Tree node, CmisSelector reference)
public List<CmisSelector> getJoinReferences()
public void addJoin(String kind, String alias, boolean hasSpec)
public List<QueryObject.JoinSpec> getJoins()
public void addWhereReference(org.antlr.runtime.tree.Tree node, CmisSelector reference)
public List<CmisSelector> getWhereReferences()
public void addWhereTypeReference(org.antlr.runtime.tree.Tree node, String qualifier)
public List<QueryObject.SortSpec> getOrderBys()
public void addSortCriterium(org.antlr.runtime.tree.Tree node, ColumnReference colRef, boolean ascending)
public boolean resolveTypes()
protected void resolveTypeForAlias(ColumnReference colRef)
protected void resolveTypeForColumnReference(ColumnReference colRef)
protected void validateColumnReferenceAndResolveType(ColumnReference colRef)
protected void validateColumnReferenceAndResolveType(TypeDefinition td, ColumnReference colRef)
protected String getReferencedTypeQueryName(String qualifier)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |