public interface UnfilteredRowIterator extends java.util.Iterator<Unfiltered>, java.lang.AutoCloseable
An UnfilteredRowIterator
contains a few partition top-level informations and is an
iterator of Unfiltered
, that is of either Row
or RangeTombstoneMarker
.
An implementation of UnfilteredRowIterator
must provide the following
guarantees:
1. the returned Unfiltered
must be in clustering order, or in reverse clustering
order iff isReverseOrder()
returns true.
2. the iterator should not shadow its own data. That is, no deletion
(partition level deletion, row deletion, range tombstone, complex
deletion) should delete anything else returned by the iterator (cell, row, ...).
3. every "start" range tombstone marker should have a corresponding "end" marker, and no other
marker should be in-between this start-end pair of marker. Note that due to the
previous rule this means that between a "start" and a corresponding "end" marker there
can only be rows that are not deleted by the markers. Also note that when iterating
in reverse order, "end" markers are returned before their "start" counterpart (i.e.
"start" and "end" are always in the sense of the clustering order).
Note further that the objects returned by next() are only valid until the
next call to hasNext() or next(). If a consumer wants to keep a reference on
the returned objects for longer than the iteration, it must make a copy of
it explicitly.
Modifier and Type | Method and Description |
---|---|
void |
close() |
PartitionColumns |
columns()
A subset of the columns for the (static and regular) rows returned by this iterator.
|
default boolean |
isEmpty()
Returns whether this iterator has no data (including no deletion data).
|
boolean |
isReverseOrder()
Whether or not the atom returned by this iterator are in reversed
clustering order.
|
CFMetaData |
metadata()
The metadata for the table this iterator on.
|
DecoratedKey |
partitionKey()
The partition key of the partition this in an iterator over.
|
DeletionTime |
partitionLevelDeletion()
The partition level deletion for the partition this iterate over.
|
Row |
staticRow()
The static part corresponding to this partition (this can be an empty
row).
|
EncodingStats |
stats()
Return "statistics" about what is returned by this iterator.
|
CFMetaData metadata()
PartitionColumns columns()
boolean isReverseOrder()
DecoratedKey partitionKey()
DeletionTime partitionLevelDeletion()
Row staticRow()
EncodingStats stats()
void close()
close
in interface java.lang.AutoCloseable
default boolean isEmpty()
Copyright © 2015 The Apache Software Foundation