CompressedStreamReader (apache-cassandra API)
Date: 2014-10-21

org.apache.cassandra.streaming.compress

## Class CompressedStreamReader

- java.lang.Object
- - org.apache.cassandra.streaming.StreamReader
  - - org.apache.cassandra.streaming.compress.CompressedStreamReader

-     public class CompressedStreamReader
      extends StreamReader

  StreamReader that reads from streamed compressed SSTable

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected CompressionInfo` | `compressionInfo`

    - ### Fields inherited from class org.apache.cassandra.streaming.StreamReader

      `cfId, desc, estimatedKeys, inputVersion, repairedAt, sections, session`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `CompressedStreamReader(FileMessageHeader header, StreamSession session)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `SSTableWriter` | `read(java.nio.channels.ReadableByteChannel channel)`
    `protected long` | `totalSize()`

    - ### Methods inherited from class org.apache.cassandra.streaming.StreamReader

      `createWriter, drain, writeRow`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### compressionInfo

          protected final CompressionInfo compressionInfo

  - ### Constructor Detail

    - #### CompressedStreamReader

          public CompressedStreamReader(FileMessageHeader header,
                                StreamSession session)

  - ### Method Detail

    - #### read

          public SSTableWriter read(java.nio.channels.ReadableByteChannel channel)
                             throws java.io.IOException

      Overrides:
        `read` in class `StreamReader`
      Parameters:
        `channel` - where this reads data from
      Returns:
        SSTable transferred
      Throws:
        `java.io.IOException` - if reading the remote sstable fails. Will throw an RTE if local write fails.

    - #### totalSize

          protected long totalSize()

      Overrides:
        `totalSize` in class `StreamReader`

Copyright © 2014 The Apache Software Foundation