Class BufferCell


  • public class BufferCell
    extends AbstractCell<java.nio.ByteBuffer>
    • Constructor Detail

      • BufferCell

        public BufferCell​(ColumnMetadata column,
                          long timestamp,
                          int ttl,
                          int localDeletionTime,
                          java.nio.ByteBuffer value,
                          CellPath path)
    • Method Detail

      • expiring

        public static BufferCell expiring​(ColumnMetadata column,
                                          long timestamp,
                                          int ttl,
                                          int nowInSec,
                                          java.nio.ByteBuffer value)
      • timestamp

        public long timestamp()
        Description copied from class: Cell
        The cell timestamp.

        Specified by:
        timestamp in class Cell<java.nio.ByteBuffer>
        Returns:
        the cell timestamp.
      • ttl

        public int ttl()
        Description copied from class: Cell
        The cell ttl.
        Specified by:
        ttl in class Cell<java.nio.ByteBuffer>
        Returns:
        the cell ttl, or NO_TTL if the cell isn't an expiring one.
      • localDeletionTime

        public int localDeletionTime()
        Description copied from class: Cell
        The cell local deletion time.
        Specified by:
        localDeletionTime in class Cell<java.nio.ByteBuffer>
        Returns:
        the cell local deletion time, or NO_DELETION_TIME if the cell is neither a tombstone nor an expiring one.
      • value

        public java.nio.ByteBuffer value()
        Specified by:
        value in class Cell<java.nio.ByteBuffer>
      • accessor

        public ValueAccessor<java.nio.ByteBuffer> accessor()
        Specified by:
        accessor in class Cell<java.nio.ByteBuffer>
      • path

        public CellPath path()
        Description copied from class: Cell
        For cells belonging to complex types (non-frozen collection and UDT), the path to the cell.
        Specified by:
        path in class Cell<java.nio.ByteBuffer>
        Returns:
        the cell path for cells of complex column, and null for other cells.
      • withUpdatedValue

        public Cell<?> withUpdatedValue​(java.nio.ByteBuffer newValue)
        Specified by:
        withUpdatedValue in class Cell<java.nio.ByteBuffer>
      • withUpdatedTimestampAndLocalDeletionTime

        public Cell<?> withUpdatedTimestampAndLocalDeletionTime​(long newTimestamp,
                                                                int newLocalDeletionTime)
        Specified by:
        withUpdatedTimestampAndLocalDeletionTime in class Cell<java.nio.ByteBuffer>
      • withSkippedValue

        public Cell<?> withSkippedValue()
        Description copied from class: Cell
        Used to apply the same optimization as in Cell.Serializer.deserialize(org.apache.cassandra.io.util.DataInputPlus, org.apache.cassandra.db.LivenessInfo, org.apache.cassandra.schema.ColumnMetadata, org.apache.cassandra.db.SerializationHeader, org.apache.cassandra.db.rows.DeserializationHelper, org.apache.cassandra.db.marshal.ValueAccessor<V>) when the column is not queried but eventhough it's used for digest calculation.
        Specified by:
        withSkippedValue in class Cell<java.nio.ByteBuffer>
        Returns:
        a cell with an empty buffer as value