Class CompressionInfo
- java.lang.Object
-
- org.apache.cassandra.db.streaming.CompressionInfo
-
public abstract class CompressionInfo extends java.lang.Object
Container that carries compression parameters and chunks to decompress data from stream.
-
-
Field Summary
Fields Modifier and Type Field Description static IVersionedSerializer<CompressionInfo>
serializer
-
Constructor Summary
Constructors Constructor Description CompressionInfo()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract CompressionMetadata.Chunk[]
chunks()
Returns the offset and length of the file chunks.boolean
equals(java.lang.Object o)
long
getTotalSize()
Computes the size of the file to transfer.int
hashCode()
static CompressionInfo
newInstance(CompressionMetadata.Chunk[] chunks, CompressionParams parameters)
Create aCompressionInfo
instance which is fully initialized.abstract CompressionParams
parameters()
Returns the compression parameters.
-
-
-
Field Detail
-
serializer
public static final IVersionedSerializer<CompressionInfo> serializer
-
-
Method Detail
-
parameters
public abstract CompressionParams parameters()
Returns the compression parameters.- Returns:
- the compression parameters.
-
chunks
public abstract CompressionMetadata.Chunk[] chunks()
Returns the offset and length of the file chunks.- Returns:
- the offset and length of the file chunks.
-
getTotalSize
public long getTotalSize()
Computes the size of the file to transfer.- Returns:
- the size of the file in bytes
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
newInstance
public static CompressionInfo newInstance(CompressionMetadata.Chunk[] chunks, CompressionParams parameters)
Create aCompressionInfo
instance which is fully initialized.- Parameters:
chunks
- the file chunksparameters
- the compression parameters
-
-