org.apache.cassandra.hints

## Class EncryptedHintsWriter

- java.lang.Object
- - org.apache.cassandra.hints.EncryptedHintsWriter

- All Implemented Interfaces:
    java.lang.AutoCloseable

      public class EncryptedHintsWriter
      extends java.lang.Object

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected java.nio.channels.FileChannel` | `channel`
    `protected java.util.zip.CRC32` | `globalCRC`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `EncryptedHintsWriter(java.io.File directory, org.apache.cassandra.hints.HintsDescriptor descriptor, java.io.File file, java.nio.channels.FileChannel channel, int fd, java.util.zip.CRC32 globalCRC)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()`
    `void` | `fsync()`
    `protected void` | `writeBuffer(java.nio.ByteBuffer input)` Writes byte buffer into the file channel.

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

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

- - ### Field Detail

    - #### channel

          protected final java.nio.channels.FileChannel channel

    - #### globalCRC

          protected final java.util.zip.CRC32 globalCRC

  - ### Constructor Detail

    - #### EncryptedHintsWriter

          protected EncryptedHintsWriter(java.io.File directory,
                                         org.apache.cassandra.hints.HintsDescriptor descriptor,
                                         java.io.File file,
                                         java.nio.channels.FileChannel channel,
                                         int fd,
                                         java.util.zip.CRC32 globalCRC)

  - ### Method Detail

    - #### writeBuffer

          protected void writeBuffer(java.nio.ByteBuffer input)
                              throws java.io.IOException

      Writes byte buffer into the file channel. Buffer should be flipped before calling this
      Throws:
        `java.io.IOException`

    - #### close

          public void close()

      Specified by:
        `close` in interface `java.lang.AutoCloseable`

    - #### fsync

          public void fsync()

Copyright © 2018 The Apache Software Foundation