TermSlice (apache-cassandra API)
Date: 2018-02-14

org.apache.cassandra.cql3.restrictions

## Class TermSlice

- java.lang.Object
- - org.apache.cassandra.cql3.restrictions.TermSlice

-     public final class TermSlice
      extends java.lang.Object

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addFunctionsTo(java.util.List<Function> functions)`
    `Term` | `bound(Bound bound)` Returns the boundary value.
    `Operator` | `getIndexOperator(Bound b)` Returns the index operator corresponding to the specified boundary.
    `boolean` | `hasBound(Bound b)` Checks if this slice has a boundary for the specified type.
    `boolean` | `isInclusive(Bound b)` Checks if this slice boundary is inclusive for the specified type.
    `boolean` | `isSupportedBy(ColumnDefinition column, Index index)` Check if this `TermSlice` is supported by the specified index.
    `TermSlice` | `merge(TermSlice otherSlice)` Merges this slice with the specified one.
    `static TermSlice` | `newInstance(Bound bound, boolean include, Term term)` Creates a new `TermSlice` with the specified boundary.
    `java.lang.String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Method Detail

    - #### newInstance

          public static TermSlice newInstance(Bound bound,
                                              boolean include,
                                              Term term)

      Creates a new `TermSlice` with the specified boundary.
      Parameters:
        `bound` - the boundary type
        `include` - `true` if the boundary is inclusive
        `term` - the value
      Returns:
        a new `TermSlice` instance

    - #### bound

          public Term bound(Bound bound)

      Returns the boundary value.
      Parameters:
        `bound` - the boundary type
      Returns:
        the boundary value

    - #### hasBound

          public boolean hasBound(Bound b)

      Checks if this slice has a boundary for the specified type.
      Parameters:
        `b` - the boundary type
      Returns:
        `true` if this slice has a boundary for the specified type, `false` otherwise.

    - #### isInclusive

          public boolean isInclusive(Bound b)

      Checks if this slice boundary is inclusive for the specified type.
      Parameters:
        `b` - the boundary type
      Returns:
        `true` if this slice boundary is inclusive for the specified type, `false` otherwise.

    - #### merge

          public TermSlice merge(TermSlice otherSlice)

      Merges this slice with the specified one.
      Parameters:
        `otherSlice` - the slice to merge to
      Returns:
        the new slice resulting from the merge

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

    - #### getIndexOperator

          public Operator getIndexOperator(Bound b)

      Returns the index operator corresponding to the specified boundary.
      Parameters:
        `b` - the boundary type
      Returns:
        the index operator corresponding to the specified boundary

    - #### isSupportedBy

          public boolean isSupportedBy(ColumnDefinition column,
                                       Index index)

      Check if this `TermSlice` is supported by the specified index.
      Parameters:
        `index` - the secondary index
      Returns:
        `true` this type of `TermSlice` is supported by the specified index, `false` otherwise.

    - #### addFunctionsTo

          public void addFunctionsTo(java.util.List<Function> functions)

Copyright © 2018 The Apache Software Foundation