QueryPagers (apache-cassandra API)
Date: 2014-10-21

org.apache.cassandra.service.pager

## Class QueryPagers

- java.lang.Object
- - org.apache.cassandra.service.pager.QueryPagers

-     public class QueryPagers
      extends java.lang.Object

  Static utility methods to create query pagers.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static int` | `countPaged(java.lang.String keyspace, java.lang.String columnFamily, java.nio.ByteBuffer key, SliceQueryFilter filter, ConsistencyLevel consistencyLevel, int pageSize, long now)` Convenience method that count (live) cells/rows for a given slice of a row, but page underneath.
    `static QueryPager` | `localPager(Pageable command)`
    `static boolean` | `mayNeedPaging(Pageable command, int pageSize)`
    `static QueryPager` | `pager(Pageable command, ConsistencyLevel consistencyLevel)`
    `static QueryPager` | `pager(Pageable command, ConsistencyLevel consistencyLevel, PagingState state)`
    `static java.util.Iterator<ColumnFamily>` | `pageRowLocally(ColumnFamilyStore cfs, java.nio.ByteBuffer key, int pageSize)` Convenience method to (locally) page an internal row.

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

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

- - ### Method Detail

    - #### mayNeedPaging

          public static boolean mayNeedPaging(Pageable command,
                              int pageSize)

    - #### pager

          public static QueryPager pager(Pageable command,
                         ConsistencyLevel consistencyLevel)

    - #### pager

          public static QueryPager pager(Pageable command,
                         ConsistencyLevel consistencyLevel,
                         PagingState state)

    - #### localPager

          public static QueryPager localPager(Pageable command)

    - #### pageRowLocally

          public static java.util.Iterator<ColumnFamily> pageRowLocally(ColumnFamilyStore cfs,
                                                        java.nio.ByteBuffer key,
                                                        int pageSize)

      Convenience method to (locally) page an internal row. Used to 2ndary index a wide row without dying.

    - #### countPaged

          public static int countPaged(java.lang.String keyspace,
                       java.lang.String columnFamily,
                       java.nio.ByteBuffer key,
                       SliceQueryFilter filter,
                       ConsistencyLevel consistencyLevel,
                       int pageSize,
                       long now)
                                throws RequestValidationException,
                                       RequestExecutionException

      Convenience method that count (live) cells/rows for a given slice of a row, but page underneath.
      Throws:
        `RequestValidationException`
        `RequestExecutionException`

Copyright © 2014 The Apache Software Foundation