|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.teiid.query.sql.lang.Criteria
org.teiid.query.sql.lang.PredicateCriteria
org.teiid.query.sql.lang.AbstractCompareCriteria
org.teiid.query.sql.lang.SubqueryCompareCriteria
public class SubqueryCompareCriteria
This class implements a quantified comparison predicate. This is a criteria which represents a simple operator relationship between an expression and either a scalar subquery or a table subquery preceded by one of the possible quantifiers.
The quantifiers are:
#NO_QUANTIFIER
, meaning the subquery has no quantifier and therefore must be
a scalar subquerySOME
and ANY
, which are synonymous - the criteria is true if there is at
least one comparison between the left expression and the values of the subquery. The criteria
is false if the subquery returns no rows.ALL
Some examples are:
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.teiid.query.sql.lang.PredicateCriteria |
---|
PredicateCriteria.Negatable |
Nested classes/interfaces inherited from interface org.teiid.query.sql.LanguageObject |
---|
LanguageObject.Util |
Field Summary | |
---|---|
static int |
ALL
"All" predicate quantifier |
static int |
ANY
"Any" predicate quantifier (equivalent to "Some") |
static int |
SOME
"Some" predicate quantifier (equivalent to "Any") |
Fields inherited from class org.teiid.query.sql.lang.AbstractCompareCriteria |
---|
EQ, GE, GT, LE, LT, NE |
Constructor Summary | |
---|---|
SubqueryCompareCriteria()
|
|
SubqueryCompareCriteria(Expression leftExpression,
QueryCommand subCommand,
int operator,
int predicateQuantifier)
|
Method Summary | |
---|---|
void |
acceptVisitor(LanguageVisitor visitor)
Method for accepting a visitor. |
java.lang.Object |
clone()
Deep copy of object. |
boolean |
equals(java.lang.Object obj)
Override equals() method. |
QueryCommand |
getCommand()
Returns the subquery Command object |
java.lang.String |
getContextSymbol()
|
int |
getPredicateQuantifier()
Get the predicate quantifier - returns one of the following: #NO_QUANTIFIER
ANY
SOME
ALL |
java.lang.String |
getPredicateQuantifierAsString()
Returns the predicate quantifier as a string. |
Expression |
getRightExpression()
|
Expression |
getValueExpression()
|
int |
hashCode()
Get hash code. |
void |
setCommand(QueryCommand command)
Set the subquery command (either a SELECT or a procedure execution). |
void |
setPredicateQuantifier(int predicateQuantifier)
Set the predicate quantifier - use one of the following: #NO_QUANTIFIER
ANY
SOME
ALL |
Methods inherited from class org.teiid.query.sql.lang.AbstractCompareCriteria |
---|
getLeftExpression, getOperator, getOperator, getOperatorAsString, setLeftExpression, setOperator |
Methods inherited from class org.teiid.query.sql.lang.Criteria |
---|
combineCriteria, combineCriteria, combineCriteria, getType, isResolved, separateCriteriaByAnd, toConjunctiveNormalForm, toDisjunctiveNormalForm, toString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int SOME
public static final int ANY
public static final int ALL
Constructor Detail |
---|
public SubqueryCompareCriteria()
public SubqueryCompareCriteria(Expression leftExpression, QueryCommand subCommand, int operator, int predicateQuantifier)
Method Detail |
---|
public java.lang.String getContextSymbol()
getContextSymbol
in interface ContextReference
public Expression getValueExpression()
getValueExpression
in interface ContextReference
public int getPredicateQuantifier()
public void setPredicateQuantifier(int predicateQuantifier)
predicateQuantifier
- the predicate quantifierpublic QueryCommand getCommand()
SubqueryContainer
getCommand
in interface SubqueryContainer<QueryCommand>
public void setCommand(QueryCommand command)
setCommand
in interface SubqueryContainer<QueryCommand>
command
- Command to execute to get the values for the criteriapublic java.lang.String getPredicateQuantifierAsString()
public void acceptVisitor(LanguageVisitor visitor)
LanguageObject
acceptVisitor
in interface LanguageObject
visitor
- Visitor being usedpublic int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- Other object
public java.lang.Object clone()
clone
in interface LanguageObject
clone
in class PredicateCriteria
Object.clone()
public Expression getRightExpression()
getRightExpression
in class AbstractCompareCriteria
AbstractCompareCriteria.getRightExpression()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |