org.apache.cassandra.streaming.compress

## Class CompressedStreamWriter

- java.lang.Object
- - org.apache.cassandra.streaming.StreamWriter
  - - org.apache.cassandra.streaming.compress.CompressedStreamWriter

-     public class CompressedStreamWriter
      extends StreamWriter

  StreamWriter for compressed SSTable.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `CHUNK_SIZE`

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

      `limiter, sections, session, sstable`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `CompressedStreamWriter(SSTableReader sstable, java.util.Collection<Pair<java.lang.Long,java.lang.Long>> sections, CompressionInfo compressionInfo, StreamSession session)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected long` | `totalSize()`
    `void` | `write(DataOutputStreamPlus out)` Stream file of specified sections to given channel.

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

      `write`

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

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

- - ### Field Detail

    - #### CHUNK_SIZE

          public static final int CHUNK_SIZE

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### CompressedStreamWriter

          public CompressedStreamWriter(SSTableReader sstable,
                                        java.util.Collection<Pair<java.lang.Long,java.lang.Long>> sections,
                                        CompressionInfo compressionInfo,
                                        StreamSession session)

  - ### Method Detail

    - #### write

          public void write(DataOutputStreamPlus out)
                     throws java.io.IOException

      Description copied from class: `StreamWriter`
      Stream file of specified sections to given channel. StreamWriter uses LZF compression on wire to decrease size to transfer.
      Overrides:
        `write` in class `StreamWriter`
      Parameters:
        `out` - where this writes data to
      Throws:
        `java.io.IOException` - on any I/O error

    - #### totalSize

          protected long totalSize()

      Overrides:
        `totalSize` in class `StreamWriter`

Copyright © 2018 The Apache Software Foundation