Class ImmutableBTreePartition
java.lang.Object
org.apache.cassandra.db.partitions.AbstractBTreePartition
org.apache.cassandra.db.partitions.ImmutableBTreePartition
- Direct Known Subclasses:
CachedBTreePartition,FilteredPartition
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final BTreePartitionDataprotected final TableMetadataFields inherited from class org.apache.cassandra.db.partitions.AbstractBTreePartition
partitionKey -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedImmutableBTreePartition(TableMetadata metadata, DecoratedKey partitionKey, BTreePartitionData holder) ImmutableBTreePartition(TableMetadata metadata, DecoratedKey partitionKey, RegularAndStaticColumns columns, Row staticRow, Object[] tree, DeletionInfo deletionInfo, EncodingStats stats) -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanstatic ImmutableBTreePartitioncreate(UnfilteredRowIterator iterator) Creates anImmutableBTreePartitionholding all the data of the provided iterator.static ImmutableBTreePartitioncreate(UnfilteredRowIterator iterator, boolean ordered) Creates anImmutableBTreePartitionholding all the data of the provided iterator.static ImmutableBTreePartitioncreate(UnfilteredRowIterator iterator, int initialRowCapacity) Creates anImmutableBTreePartitionholding all the data of the provided iterator.static ImmutableBTreePartitioncreate(UnfilteredRowIterator iterator, int initialRowCapacity, boolean ordered) Creates anImmutableBTreePartitionholding all the data of the provided iterator.protected BTreePartitionDataholder()metadata()Methods inherited from class org.apache.cassandra.db.partitions.AbstractBTreePartition
build, build, build, columns, deletionInfo, equals, getRow, hasRows, isEmpty, iterator, lastRow, partitionKey, partitionLevelDeletion, rowCount, staticRow, stats, toString, toString, unfilteredIterator, unfilteredIterator, unfilteredIterator, unfilteredIteratorMethods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
holder
-
metadata
-
-
Constructor Details
-
ImmutableBTreePartition
public ImmutableBTreePartition(TableMetadata metadata, DecoratedKey partitionKey, RegularAndStaticColumns columns, Row staticRow, Object[] tree, DeletionInfo deletionInfo, EncodingStats stats) -
ImmutableBTreePartition
protected ImmutableBTreePartition(TableMetadata metadata, DecoratedKey partitionKey, BTreePartitionData holder)
-
-
Method Details
-
create
Creates anImmutableBTreePartitionholding all the data of the provided iterator. Warning: Note that this method does not close the provided iterator and it is up to the caller to do so.- Parameters:
iterator- the iterator to gather in memory.- Returns:
- the created partition.
-
create
Creates anImmutableBTreePartitionholding all the data of the provided iterator. Warning: Note that this method does not close the provided iterator and it is up to the caller to do so.- Parameters:
iterator- the iterator to gather in memory.ordered-trueif the iterator will return the rows in order,falseotherwise.- Returns:
- the created partition.
-
create
public static ImmutableBTreePartition create(UnfilteredRowIterator iterator, int initialRowCapacity) Creates anImmutableBTreePartitionholding all the data of the provided iterator. Warning: Note that this method does not close the provided iterator and it is up to the caller to do so.- Parameters:
iterator- the iterator to gather in memory.initialRowCapacity- sizing hint (in rows) to use for the created partition. It should ideally correspond or be a good estimation of the number or rows initerator.- Returns:
- the created partition.
-
create
public static ImmutableBTreePartition create(UnfilteredRowIterator iterator, int initialRowCapacity, boolean ordered) Creates anImmutableBTreePartitionholding all the data of the provided iterator. Warning: Note that this method does not close the provided iterator and it is up to the caller to do so.- Parameters:
iterator- the iterator to gather in memory.initialRowCapacity- sizing hint (in rows) to use for the created partition. It should ideally correspond or be a good estimation of the number or rows initerator.ordered-trueif the iterator will return the rows in order,falseotherwise.- Returns:
- the created partition.
-
metadata
- Specified by:
metadatain interfacePartition- Specified by:
metadatain classAbstractBTreePartition
-
holder
- Specified by:
holderin classAbstractBTreePartition
-
canHaveShadowedData
protected boolean canHaveShadowedData()- Specified by:
canHaveShadowedDatain classAbstractBTreePartition
-