Class BaseRows<R extends Unfiltered,I extends BaseRowIterator<? extends Unfiltered>>
- java.lang.Object
-
- org.apache.cassandra.db.transform.BaseRows<R,I>
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,java.util.Iterator<R>
,BaseRowIterator<R>
,CloseableIterator<R>
- Direct Known Subclasses:
FilteredRows
public abstract class BaseRows<R extends Unfiltered,I extends BaseRowIterator<? extends Unfiltered>> extends java.lang.Object implements BaseRowIterator<R>
-
-
Field Summary
Fields Modifier and Type Field Description static org.apache.cassandra.db.transform.Stack.MoreContentsHolder[]
EMPTY_MORE_CONTENTS_HOLDERS
static Transformation[]
EMPTY_TRANSFORMATIONS
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Unfiltered
applyOne(Unfiltered value, Transformation transformation)
apply the relevant method from the transformation to the value.void
close()
RegularAndStaticColumns
columns()
A subset of the columns for the (static and regular) rows returned by this iterator.protected boolean
hasMoreContents()
boolean
hasNext()
boolean
isReverseOrder()
Whether or not the rows returned by this iterator are in reversed clustering order.TableMetadata
metadata()
The metadata for the table this iterator on.O
next()
DecoratedKey
partitionKey()
The partition key of the partition this in an iterator over.protected java.lang.Throwable
runOnClose(int length)
run the corresponding runOnClose method for the first length transformations.Row
staticRow()
The static part corresponding to this partition (this can be an empty row but cannot benull
).-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.cassandra.db.rows.BaseRowIterator
isEmpty
-
Methods inherited from interface org.apache.cassandra.utils.CloseableIterator
close
-
-
-
-
Field Detail
-
EMPTY_TRANSFORMATIONS
public static final Transformation[] EMPTY_TRANSFORMATIONS
-
EMPTY_MORE_CONTENTS_HOLDERS
public static final org.apache.cassandra.db.transform.Stack.MoreContentsHolder[] EMPTY_MORE_CONTENTS_HOLDERS
-
-
Constructor Detail
-
BaseRows
public BaseRows(I input)
-
-
Method Detail
-
metadata
public TableMetadata metadata()
Description copied from interface:BaseRowIterator
The metadata for the table this iterator on.- Specified by:
metadata
in interfaceBaseRowIterator<R extends Unfiltered>
-
isReverseOrder
public boolean isReverseOrder()
Description copied from interface:BaseRowIterator
Whether or not the rows returned by this iterator are in reversed clustering order.- Specified by:
isReverseOrder
in interfaceBaseRowIterator<R extends Unfiltered>
-
columns
public RegularAndStaticColumns columns()
Description copied from interface:BaseRowIterator
A subset of the columns for the (static and regular) rows returned by this iterator. Every row returned by this iterator must guarantee that it has only those columns.- Specified by:
columns
in interfaceBaseRowIterator<R extends Unfiltered>
-
partitionKey
public DecoratedKey partitionKey()
Description copied from interface:BaseRowIterator
The partition key of the partition this in an iterator over.- Specified by:
partitionKey
in interfaceBaseRowIterator<R extends Unfiltered>
-
staticRow
public Row staticRow()
Description copied from interface:BaseRowIterator
The static part corresponding to this partition (this can be an empty row but cannot benull
).- Specified by:
staticRow
in interfaceBaseRowIterator<R extends Unfiltered>
-
runOnClose
protected java.lang.Throwable runOnClose(int length)
run the corresponding runOnClose method for the first length transformations. used in hasMoreContents to close the methods preceding the MoreContents
-
applyOne
protected Unfiltered applyOne(Unfiltered value, Transformation transformation)
apply the relevant method from the transformation to the value. used in hasMoreContents to apply the functions that follow the MoreContents
-
hasNext
public final boolean hasNext()
- Specified by:
hasNext
in interfacejava.util.Iterator<R extends Unfiltered>
-
close
public final void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
-
next
public final O next()
- Specified by:
next
in interfacejava.util.Iterator<V>
-
hasMoreContents
protected final boolean hasMoreContents()
-
-