org.apache.cassandra.db.partitions

## Class UnfilteredPartitionIterators

- java.lang.Object
- - org.apache.cassandra.db.partitions.UnfilteredPartitionIterators

    public abstract class UnfilteredPartitionIterators
    extends java.lang.Object

Static methods to work with partition iterators.

### Nested Class Summary

Nested Classes
`static interface` `UnfilteredPartitionIterators.MergeListener`
`static class` `UnfilteredPartitionIterators.Serializer` Serialize each UnfilteredSerializer one after the other, with an initial byte that indicates whether we're done or not.

### Method Summary

All Methods Static Methods Concrete Methods
`static UnfilteredPartitionIterator` `concat(java.util.List<UnfilteredPartitionIterator> iterators)`
`static void` `digest(ReadCommand command, UnfilteredPartitionIterator iterator, java.security.MessageDigest digest, int version)` Digests the the provided iterator.
`static PartitionIterator` `filter(UnfilteredPartitionIterator iterator, int nowInSec)`
`static UnfilteredRowIterator` `getOnlyElement(UnfilteredPartitionIterator iter, SinglePartitionReadCommand command)`
`static UnfilteredPartitionIterator` `loggingIterator(UnfilteredPartitionIterator iterator, java.lang.String id, boolean fullDetails)` Wraps the provided iterator so it logs the returned rows/RT for debugging purposes.
`static UnfilteredPartitionIterator` `merge(java.util.List<? extends UnfilteredPartitionIterator> iterators, int nowInSec, UnfilteredPartitionIterators.MergeListener listener)`
`static UnfilteredPartitionIterator` `mergeLazily(java.util.List<? extends UnfilteredPartitionIterator> iterators, int nowInSec)`
`static UnfilteredPartitionIterators.Serializer` `serializerForIntraNode()`

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

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

### Method Detail

#### getOnlyElement

    public static UnfilteredRowIterator getOnlyElement(UnfilteredPartitionIterator iter,
                                                       SinglePartitionReadCommand command)

#### concat

    public static UnfilteredPartitionIterator concat(java.util.List<UnfilteredPartitionIterator> iterators)

#### filter

    public static PartitionIterator filter(UnfilteredPartitionIterator iterator,
                                           int nowInSec)

#### merge

    public static UnfilteredPartitionIterator merge(java.util.List<? extends UnfilteredPartitionIterator> iterators,
                                                    int nowInSec,
                                                    UnfilteredPartitionIterators.MergeListener listener)

#### mergeLazily

    public static UnfilteredPartitionIterator mergeLazily(java.util.List<? extends UnfilteredPartitionIterator> iterators,
                                                          int nowInSec)

#### digest

    public static void digest(ReadCommand command,
                              UnfilteredPartitionIterator iterator,
                              java.security.MessageDigest digest,
                              int version)

Digests the the provided iterator.

Parameters:
  `command` - the command that has yield `iterator`. This can be null if `version >= MessagingService.VERSION_30` as this is only used when producing digest to be sent to legacy nodes.
  `iterator` - the iterator to digest.
  `digest` - the `MessageDigest` to use for the digest.
  `version` - the messaging protocol to use when producing the digest.

#### serializerForIntraNode

    public static UnfilteredPartitionIterators.Serializer serializerForIntraNode()

#### loggingIterator

    public static UnfilteredPartitionIterator loggingIterator(UnfilteredPartitionIterator iterator,
                                                              java.lang.String id,
                                                              boolean fullDetails)

Wraps the provided iterator so it logs the returned rows/RT for debugging purposes.

Note that this is only meant for debugging as this can log a very large amount of logging at INFO.