public static class SingleColumnRestriction.SliceRestriction extends SingleColumnRestriction
SingleColumnRestriction.ContainsRestriction, SingleColumnRestriction.EQRestriction, SingleColumnRestriction.INRestriction, SingleColumnRestriction.InRestrictionWithMarker, SingleColumnRestriction.InRestrictionWithValues, SingleColumnRestriction.IsNotNullRestriction, SingleColumnRestriction.SliceRestriction
columnDef
Constructor and Description |
---|
SliceRestriction(ColumnDefinition columnDef,
Bound bound,
boolean inclusive,
Term term) |
Modifier and Type | Method and Description |
---|---|
void |
addRowFilterTo(RowFilter filter,
SecondaryIndexManager indexManager,
QueryOptions options)
Adds to the specified row filter the expressions corresponding to this
Restriction . |
MultiCBuilder |
appendBoundTo(MultiCBuilder builder,
Bound bound,
QueryOptions options)
Appends the values of the
Restriction for the specified bound to the specified builder. |
MultiCBuilder |
appendTo(MultiCBuilder builder,
QueryOptions options)
Appends the values of this
Restriction to the specified builder. |
Restriction |
doMergeWith(Restriction otherRestriction) |
java.lang.Iterable<Function> |
getFunctions()
Return an Iterable over all of the functions (both native and user-defined) used by any component
of the restriction
|
boolean |
hasBound(Bound b)
Checks if the specified bound is set or not.
|
boolean |
isContains() |
boolean |
isEQ() |
boolean |
isIN() |
boolean |
isInclusive(Bound b)
Checks if the specified bound is inclusive or not.
|
boolean |
isMultiColumn() |
boolean |
isNotNull() |
boolean |
isOnToken() |
boolean |
isSlice() |
protected boolean |
isSupportedBy(Index index)
Check if this type of restriction is supported by the specified index.
|
java.lang.String |
toString() |
getColumnDefs, getFirstColumn, getLastColumn, hasSupportingIndex, mergeWith
public SliceRestriction(ColumnDefinition columnDef, Bound bound, boolean inclusive, Term term)
public java.lang.Iterable<Function> getFunctions()
Restriction
public boolean isSlice()
isSlice
in interface Restriction
public MultiCBuilder appendTo(MultiCBuilder builder, QueryOptions options)
Restriction
Restriction
to the specified builder.builder
- the MultiCBuilder
to append to.options
- the query optionsMultiCBuilder
public boolean hasBound(Bound b)
Restriction
hasBound
in interface Restriction
b
- the bound typetrue
if the specified bound is set, false
otherwisepublic MultiCBuilder appendBoundTo(MultiCBuilder builder, Bound bound, QueryOptions options)
Restriction
Restriction
for the specified bound to the specified builder.appendBoundTo
in interface Restriction
builder
- the MultiCBuilder
to append to.bound
- the boundoptions
- the query optionsMultiCBuilder
public boolean isInclusive(Bound b)
Restriction
isInclusive
in interface Restriction
b
- the bound typetrue
if the specified bound is inclusive, false
otherwisepublic Restriction doMergeWith(Restriction otherRestriction) throws InvalidRequestException
doMergeWith
in class SingleColumnRestriction
InvalidRequestException
public void addRowFilterTo(RowFilter filter, SecondaryIndexManager indexManager, QueryOptions options) throws InvalidRequestException
Restriction
Restriction
.filter
- the row filter to add expressions toindexManager
- the secondary index manageroptions
- the query optionsInvalidRequestException
- if this Restriction
cannot be converted into a row filterprotected boolean isSupportedBy(Index index)
SingleColumnRestriction
isSupportedBy
in class SingleColumnRestriction
index
- the secondary indextrue
this type of restriction is supported by the specified index,
false
otherwise.public java.lang.String toString()
toString
in class java.lang.Object
public boolean isOnToken()
isOnToken
in interface Restriction
public boolean isMultiColumn()
isMultiColumn
in interface Restriction
public boolean isEQ()
isEQ
in interface Restriction
public boolean isIN()
isIN
in interface Restriction
public boolean isContains()
isContains
in interface Restriction
public boolean isNotNull()
isNotNull
in interface Restriction
Copyright © 2015 The Apache Software Foundation