|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.teiid.query.resolver.QueryResolver
public class QueryResolver
The QueryResolver is used between Parsing and QueryValidation. The SQL queries, inserts, updates and deletes are parsed and converted into objects. The language objects have variable names which resolved to fully qualified names using metadata information. The resolver is also used in transforming the values in language objects to their variable types defined in metadata.
| Constructor Summary | |
|---|---|
QueryResolver()
|
|
| Method Summary | |
|---|---|
static Command |
expandCommand(ProcedureContainer proc,
QueryMetadataInterface metadata,
AnalysisRecord analysisRecord)
|
static java.util.Map<ElementSymbol,Expression> |
getVariableValues(Command command,
boolean changingOnly,
QueryMetadataInterface metadata)
|
static boolean |
isView(GroupSymbol virtualGroup,
QueryMetadataInterface qmi)
|
static boolean |
isXMLQuery(Query query,
QueryMetadataInterface metadata)
Check to verify if the query would return XML results. |
static java.util.List<SingleElementSymbol> |
parseBindings(QueryNode planNode)
Bindings are a poor mans input parameters. |
static TempMetadataStore |
resolveCommand(Command currentCommand,
GroupSymbol container,
int type,
QueryMetadataInterface metadata)
Resolve a command in a given type container and type context. |
static TempMetadataStore |
resolveCommand(Command command,
QueryMetadataInterface metadata)
This implements an algorithm to resolve all the symbols created by the parser into real metadata IDs |
static TempMetadataStore |
resolveCommand(Command currentCommand,
QueryMetadataInterface metadata,
boolean resolveNullLiterals)
|
static void |
resolveCriteria(Criteria criteria,
QueryMetadataInterface metadata)
Resolve just a criteria. |
static void |
resolveSubqueries(Command command,
TempMetadataAdapter metadata,
java.util.Collection<GroupSymbol> externalGroups)
|
static QueryNode |
resolveView(GroupSymbol virtualGroup,
QueryNode qnode,
java.lang.String cacheString,
QueryMetadataInterface qmi)
|
static TempMetadataStore |
resolveWithBindingMetadata(Command currentCommand,
QueryMetadataInterface metadata,
QueryNode queryNode,
boolean replaceBindings)
Bindings are a poor mans input parameters. |
static void |
setChildMetadata(Command subCommand,
Command parent)
|
static void |
setChildMetadata(Command subCommand,
java.util.Map parentTempMetadata,
GroupContext parentContext)
|
static void |
validateProjectedSymbols(GroupSymbol virtualGroup,
java.util.List<ElementSymbol> symbols,
java.util.List<SingleElementSymbol> projectedSymbols)
|
static void |
validateProjectedSymbols(GroupSymbol virtualGroup,
QueryMetadataInterface qmi,
Command result)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public QueryResolver()
| Method Detail |
|---|
public static Command expandCommand(ProcedureContainer proc,
QueryMetadataInterface metadata,
AnalysisRecord analysisRecord)
throws QueryResolverException,
QueryMetadataException,
TeiidComponentException
QueryResolverException
QueryMetadataException
TeiidComponentException
public static TempMetadataStore resolveCommand(Command command,
QueryMetadataInterface metadata)
throws QueryResolverException,
TeiidComponentException
command - Command the SQL command we are running (Select, Update,
Insert, Delete)metadata - QueryMetadataInterface the metadata
QueryResolverException
TeiidComponentException
public static TempMetadataStore resolveCommand(Command currentCommand,
GroupSymbol container,
int type,
QueryMetadataInterface metadata)
throws QueryResolverException,
TeiidComponentException
type - The Command type
QueryResolverException
TeiidComponentException
public static TempMetadataStore resolveWithBindingMetadata(Command currentCommand,
QueryMetadataInterface metadata,
QueryNode queryNode,
boolean replaceBindings)
throws TeiidComponentException,
QueryResolverException
TeiidComponentException
QueryResolverException
public static java.util.List<SingleElementSymbol> parseBindings(QueryNode planNode)
throws TeiidComponentException
planNode -
TeiidComponentException
public static TempMetadataStore resolveCommand(Command currentCommand,
QueryMetadataInterface metadata,
boolean resolveNullLiterals)
throws QueryResolverException,
TeiidComponentException
QueryResolverException
TeiidComponentException
public static boolean isXMLQuery(Query query,
QueryMetadataInterface metadata)
throws TeiidComponentException,
QueryMetadataException,
QueryResolverException
query - the query to checkmetadata - QueryMetadataInterface the metadata
TeiidComponentException
QueryMetadataException
QueryResolverException
public static void resolveCriteria(Criteria criteria,
QueryMetadataInterface metadata)
throws QueryResolverException,
QueryMetadataException,
TeiidComponentException
criteria - Criteria to resolvemetadata - Metadata implementation
QueryResolverException
QueryMetadataException
TeiidComponentException
public static void setChildMetadata(Command subCommand,
Command parent)
public static void setChildMetadata(Command subCommand,
java.util.Map parentTempMetadata,
GroupContext parentContext)
public static java.util.Map<ElementSymbol,Expression> getVariableValues(Command command,
boolean changingOnly,
QueryMetadataInterface metadata)
throws QueryMetadataException,
QueryResolverException,
TeiidComponentException
QueryMetadataException
QueryResolverException
TeiidComponentException
public static void resolveSubqueries(Command command,
TempMetadataAdapter metadata,
java.util.Collection<GroupSymbol> externalGroups)
throws QueryResolverException,
TeiidComponentException
QueryResolverException
TeiidComponentException
public static QueryNode resolveView(GroupSymbol virtualGroup,
QueryNode qnode,
java.lang.String cacheString,
QueryMetadataInterface qmi)
throws TeiidComponentException,
QueryMetadataException,
QueryResolverException,
QueryValidatorException
TeiidComponentException
QueryMetadataException
QueryResolverException
QueryValidatorException
public static void validateProjectedSymbols(GroupSymbol virtualGroup,
QueryMetadataInterface qmi,
Command result)
throws QueryMetadataException,
TeiidComponentException,
QueryValidatorException
QueryMetadataException
TeiidComponentException
QueryValidatorException
public static void validateProjectedSymbols(GroupSymbol virtualGroup,
java.util.List<ElementSymbol> symbols,
java.util.List<SingleElementSymbol> projectedSymbols)
throws QueryValidatorException
QueryValidatorException
public static boolean isView(GroupSymbol virtualGroup,
QueryMetadataInterface qmi)
throws TeiidComponentException,
QueryMetadataException
TeiidComponentException
QueryMetadataException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||