Package org.teiid.query.sql.lang
Class SubquerySetCriteria
- java.lang.Object
-
- org.teiid.query.sql.lang.Criteria
-
- org.teiid.query.sql.lang.PredicateCriteria
-
- org.teiid.query.sql.lang.AbstractSetCriteria
-
- org.teiid.query.sql.lang.SubquerySetCriteria
-
- All Implemented Interfaces:
Cloneable
,PredicateCriteria.Negatable
,SubqueryContainer<QueryCommand>
,LanguageObject
,ContextReference
,Expression
public class SubquerySetCriteria extends AbstractSetCriteria implements SubqueryContainer<QueryCommand>, ContextReference
A criteria which is true is the expression's value is a member in a list of values returned from a subquery. This criteria can be represented as "<expression> IN (SELECT ...)".
-
-
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
-
Nested classes/interfaces inherited from interface org.teiid.query.sql.lang.SubqueryContainer
SubqueryContainer.Evaluatable<T extends Command>
-
-
Constructor Summary
Constructors Constructor Description SubquerySetCriteria()
Constructor for SubquerySetCriteria.SubquerySetCriteria(Expression expression, QueryCommand subCommand)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
acceptVisitor(LanguageVisitor visitor)
Method for accepting a visitor.SubquerySetCriteria
clone()
Deep copy of object.boolean
equals(Object obj)
Override equals() method.QueryCommand
getCommand()
Get the subquery command used to produce the values for this SetCriteria.String
getContextSymbol()
ExistsCriteria.SubqueryHint
getSubqueryHint()
int
hashCode()
Get hash code.void
setCommand(QueryCommand command)
Set the subquery command (either a SELECT or a procedure execution).void
setSubqueryHint(ExistsCriteria.SubqueryHint subqueryHint)
-
Methods inherited from class org.teiid.query.sql.lang.AbstractSetCriteria
getExpression, isNegated, negate, setExpression, setNegated
-
Methods inherited from class org.teiid.query.sql.lang.Criteria
applyDemorgan, combineCriteria, combineCriteria, combineCriteria, getType, separateCriteriaByAnd, toString
-
-
-
-
Constructor Detail
-
SubquerySetCriteria
public SubquerySetCriteria()
Constructor for SubquerySetCriteria.
-
SubquerySetCriteria
public SubquerySetCriteria(Expression expression, QueryCommand subCommand)
-
-
Method Detail
-
getSubqueryHint
public ExistsCriteria.SubqueryHint getSubqueryHint()
-
setSubqueryHint
public void setSubqueryHint(ExistsCriteria.SubqueryHint subqueryHint)
-
getContextSymbol
public String getContextSymbol()
- Specified by:
getContextSymbol
in interfaceContextReference
-
setCommand
public void setCommand(QueryCommand command)
Set the subquery command (either a SELECT or a procedure execution).- Specified by:
setCommand
in interfaceSubqueryContainer<QueryCommand>
- Parameters:
command
- Command to execute to get the values for the criteria
-
getCommand
public QueryCommand getCommand()
Get the subquery command used to produce the values for this SetCriteria.- Specified by:
getCommand
in interfaceSubqueryContainer<QueryCommand>
- Returns:
- Command Command to execute
-
acceptVisitor
public void acceptVisitor(LanguageVisitor visitor)
Description copied from interface:LanguageObject
Method for accepting a visitor. It is the responsibility of the language object to call back on the visitor.- Specified by:
acceptVisitor
in interfaceLanguageObject
- Parameters:
visitor
- Visitor being used
-
hashCode
public int hashCode()
Get hash code. WARNING: The hash code is based on data in the criteria. If data values are changed, the hash code will change - don't hash this object and change values.
-
equals
public boolean equals(Object obj)
Override equals() method.
-
clone
public SubquerySetCriteria clone()
Deep copy of object. The values Iterator of this object will not be cloned - it will be null in the new object (see #setValueIterator setValueIterator}).- Specified by:
clone
in interfaceLanguageObject
- Specified by:
clone
in classAbstractSetCriteria
- Returns:
- Deep copy of object
-
-