Class Expression
java.lang.Object
org.apache.cassandra.index.sai.plan.Expression
- Direct Known Subclasses:
Expression.IndexedExpression,Expression.UnindexedExpression
An
Expression is an internal representation of an index query operation. They are built from
CQL Operator and ByteBuffer value pairs for a single column.
Each Expression consists of an Expression.IndexOperator and optional lower and upper Expression.Bounds.
The Expression.IndexedExpression has a backing StorageAttachedIndex for the index query but order to support
CQL expressions on columns that do not have indexes or use operators that are not supported by the index there is
an Expression.UnindexedExpression that does not provide a StorageAttachedIndex and can only be used for
post-filtering
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classstatic enumstatic classstatic classA representation of a column value in its raw and encoded form. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionadd(Operator op, ByteBuffer value) This adds an operation to the currentExpressioninstance and returns the current instance.static Expressioncreate(StorageAttachedIndex index) static Expressioncreate(IndexTermType indexTermType) booleanabstract StorageAttachedIndexgetIndex()inthashCode()abstract booleanbooleanisSatisfiedBy(ByteBuffer columnValue) Used in post-filtering to determine is an indexed value matches the expressionlower()static booleansupportsOperator(Operator operator) toString()upper()
-
Field Details
-
operator
-
lower
-
upper
-
upperInclusive
public boolean upperInclusive -
lowerInclusive
public boolean lowerInclusive
-
-
Method Details
-
create
-
create
-
supportsOperator
-
isNotIndexed
public abstract boolean isNotIndexed() -
getIndex
-
getIndexOperator
-
getIndexTermType
-
lower
-
upper
-
add
This adds an operation to the currentExpressioninstance and returns the current instance.- Parameters:
op- the CQL3 operationvalue- the expression value- Returns:
- the current expression with the added operation
-
isSatisfiedBy
Used in post-filtering to determine is an indexed value matches the expression -
toString
-
hashCode
public int hashCode() -
equals
-