ExtendedFilter (apache-cassandra API)
Date: 2018-02-12

org.apache.cassandra.db.filter

## Class ExtendedFilter

- java.lang.Object
- - org.apache.cassandra.db.filter.ExtendedFilter

- Direct Known Subclasses:
    ExtendedFilter.WithClauses

      public abstract class ExtendedFilter
      extends java.lang.Object

  Extends a column filter (IFilter) to include a number of IndexExpression.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `ExtendedFilter.WithClauses`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `ColumnFamilyStore` | `cfs`
    `DataRange` | `dataRange`
    `long` | `timestamp`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `ExtendedFilter(ColumnFamilyStore cfs, DataRange dataRange, int maxResults, boolean countCQL3Rows, long timestamp)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `IDiskAtomFilter` | `columnFilter(java.nio.ByteBuffer key)`
    `static ExtendedFilter` | `create(ColumnFamilyStore cfs, DataRange dataRange, java.util.List<IndexExpression> clause, int maxResults, boolean countCQL3Rows, long timestamp)`
    `int` | `currentLimit()`
    `abstract java.util.List<IndexExpression>` | `getClause()`
    `abstract IDiskAtomFilter` | `getExtraFilter(DecoratedKey key, ColumnFamily data)` Returns a filter to query the columns from the clause that the initial slice filter may not have caught.
    `boolean` | `ignoreTombstonedPartitions()` Returns true if tombstoned partitions should not be included in results or count towards the limit, false otherwise.
    `abstract boolean` | `isSatisfiedBy(DecoratedKey rowKey, ColumnFamily data, Composite prefix, java.nio.ByteBuffer collectionElement)`
    `int` | `lastCounted(ColumnFamily data)`
    `int` | `maxColumns()`
    `int` | `maxRows()`
    `abstract ColumnFamily` | `prune(DecoratedKey key, ColumnFamily data)`
    `static boolean` | `satisfies(int comparison, Operator op)`
    `java.lang.String` | `toString()`
    `void` | `updateFilter(int currentColumnsCount)`

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

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

- - ### Field Detail

    - #### cfs

          public final ColumnFamilyStore cfs

    - #### timestamp

          public final long timestamp

    - #### dataRange

          public final DataRange dataRange

  - ### Constructor Detail

    - #### ExtendedFilter

          protected ExtendedFilter(ColumnFamilyStore cfs,
                                   DataRange dataRange,
                                   int maxResults,
                                   boolean countCQL3Rows,
                                   long timestamp)

  - ### Method Detail

    - #### create

          public static ExtendedFilter create(ColumnFamilyStore cfs,
                                              DataRange dataRange,
                                              java.util.List<IndexExpression> clause,
                                              int maxResults,
                                              boolean countCQL3Rows,
                                              long timestamp)

    - #### maxRows

          public int maxRows()

    - #### maxColumns

          public int maxColumns()

    - #### currentLimit

          public int currentLimit()

    - #### columnFilter

          public IDiskAtomFilter columnFilter(java.nio.ByteBuffer key)

    - #### lastCounted

          public int lastCounted(ColumnFamily data)

    - #### updateFilter

          public void updateFilter(int currentColumnsCount)

    - #### getClause

          public abstract java.util.List<IndexExpression> getClause()

    - #### getExtraFilter

          public abstract IDiskAtomFilter getExtraFilter(DecoratedKey key,
                                                         ColumnFamily data)

      Returns a filter to query the columns from the clause that the initial slice filter may not have caught.
      Parameters:
        `data` - the data retrieve by the initial filter
      Returns:
        a filter or null if there can't be any columns we missed with our initial filter (typically if it was a names query, or a slice of the entire row)

    - #### prune

          public abstract ColumnFamily prune(DecoratedKey key,
                                             ColumnFamily data)

      Returns:
        data pruned down to the columns originally asked for

    - #### ignoreTombstonedPartitions

          public boolean ignoreTombstonedPartitions()

      Returns true if tombstoned partitions should not be included in results or count towards the limit, false otherwise.

    - #### isSatisfiedBy

          public abstract boolean isSatisfiedBy(DecoratedKey rowKey,
                                                ColumnFamily data,
                                                Composite prefix,
                                                java.nio.ByteBuffer collectionElement)

      Returns:
        true if the provided data satisfies all the expressions from the clause of this filter.

    - #### satisfies

          public static boolean satisfies(int comparison,
                                          Operator op)

    - #### toString

          public java.lang.String toString()

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

Copyright © 2018 The Apache Software Foundation