public class Cell extends java.lang.Object implements OnDiskAtom
OnDiskAtom.Serializer
Modifier and Type | Field and Description |
---|---|
static int |
MAX_NAME_LENGTH |
protected CellName |
name |
protected long |
timestamp |
protected java.nio.ByteBuffer |
value |
Constructor and Description |
---|
Cell(CellName name,
java.nio.ByteBuffer value) |
Cell(CellName name,
java.nio.ByteBuffer value,
long timestamp) |
Modifier and Type | Method and Description |
---|---|
static Cell |
create(CellName name,
java.nio.ByteBuffer value,
long timestamp,
int ttl,
CFMetaData metadata) |
int |
dataSize() |
Cell |
diff(Cell cell) |
boolean |
equals(java.lang.Object o) |
long |
excessHeapSizeExcludingData() |
int |
getLocalDeletionTime() |
long |
getMarkedForDeleteAt() |
java.lang.String |
getString(CellNameType comparator) |
int |
hashCode() |
boolean |
hasIrrelevantData(int gcBefore) |
boolean |
isLive(long now) |
boolean |
isMarkedForDelete(long now) |
Cell |
localCopy(ColumnFamilyStore cfs,
AbstractAllocator allocator) |
long |
maxTimestamp() |
long |
minTimestamp()
For a standard column, this is the same as timestamp().
|
CellName |
name() |
static java.util.Iterator<OnDiskAtom> |
onDiskIterator(java.io.DataInput in,
int count,
ColumnSerializer.Flag flag,
int expireBefore,
Descriptor.Version version,
CellNameType type)
For 2.0-formatted sstables (where column count is not stored), @param count should be Integer.MAX_VALUE,
and we will look for the end-of-row column name marker instead of relying on that.
|
Cell |
reconcile(Cell cell) |
Cell |
reconcile(Cell cell,
AbstractAllocator allocator) |
int |
serializationFlags() |
int |
serializedSize(CellNameType type,
TypeSizes typeSizes) |
long |
timestamp() |
void |
updateDigest(java.security.MessageDigest digest) |
void |
validateFields(CFMetaData metadata) |
protected void |
validateName(CFMetaData metadata) |
java.nio.ByteBuffer |
value() |
Cell |
withUpdatedName(CellName newName) |
Cell |
withUpdatedTimestamp(long newTimestamp) |
public static final int MAX_NAME_LENGTH
protected final CellName name
protected final java.nio.ByteBuffer value
protected final long timestamp
public Cell(CellName name, java.nio.ByteBuffer value)
public Cell(CellName name, java.nio.ByteBuffer value, long timestamp)
public static java.util.Iterator<OnDiskAtom> onDiskIterator(java.io.DataInput in, int count, ColumnSerializer.Flag flag, int expireBefore, Descriptor.Version version, CellNameType type)
public Cell withUpdatedTimestamp(long newTimestamp)
public CellName name()
name
in interface OnDiskAtom
public java.nio.ByteBuffer value()
public long timestamp()
public long minTimestamp()
OnDiskAtom
minTimestamp
in interface OnDiskAtom
public long maxTimestamp()
maxTimestamp
in interface OnDiskAtom
public boolean isMarkedForDelete(long now)
public boolean isLive(long now)
public long getMarkedForDeleteAt()
public int dataSize()
public long excessHeapSizeExcludingData()
public int serializedSize(CellNameType type, TypeSizes typeSizes)
public int serializationFlags()
public void updateDigest(java.security.MessageDigest digest)
updateDigest
in interface OnDiskAtom
public int getLocalDeletionTime()
getLocalDeletionTime
in interface OnDiskAtom
public Cell reconcile(Cell cell, AbstractAllocator allocator)
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public Cell localCopy(ColumnFamilyStore cfs, AbstractAllocator allocator)
public java.lang.String getString(CellNameType comparator)
protected void validateName(CFMetaData metadata) throws MarshalException
MarshalException
public void validateFields(CFMetaData metadata) throws MarshalException
validateFields
in interface OnDiskAtom
MarshalException
public boolean hasIrrelevantData(int gcBefore)
public static Cell create(CellName name, java.nio.ByteBuffer value, long timestamp, int ttl, CFMetaData metadata)
Copyright © 2014 The Apache Software Foundation