org.apache.lucene.util.packed

## Class BlockPackedReader

- java.lang.Object
- - org.apache.lucene.util.LongValues
  - - org.apache.lucene.util.packed.BlockPackedReader

- All Implemented Interfaces:
    Accountable

      public final class BlockPackedReader
      extends LongValues
      implements Accountable

  Provides random access to a stream written with `BlockPackedWriter`.
  NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.

- - ### Field Summary

    - ### Fields inherited from class org.apache.lucene.util.LongValues

      `IDENTITY, ZEROES`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `BlockPackedReader(IndexInput in, int packedIntsVersion, int blockSize, long valueCount, boolean direct)` Sole constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `long` | `get(long index)` Get value at `index`.
    `long` | `ramBytesUsed()` Return the memory usage of this object in bytes.
    `String` | `toString()`

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

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

    - ### Methods inherited from interface org.apache.lucene.util.Accountable

      `getChildResources`

- - ### Constructor Detail

    - #### BlockPackedReader

          public BlockPackedReader(IndexInput in,
                                   int packedIntsVersion,
                                   int blockSize,
                                   long valueCount,
                                   boolean direct)
                            throws IOException

      Sole constructor.
      Throws:
        `IOException`

  - ### Method Detail

    - #### get

          public long get(long index)

      Description copied from class: `LongValues`
      Get value at `index`.
      Specified by:
        `get` in class `LongValues`

    - #### ramBytesUsed

          public long ramBytesUsed()

      Description copied from interface: `Accountable`
      Return the memory usage of this object in bytes. Negative values are illegal.
      Specified by:
        `ramBytesUsed` in interface `Accountable`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2000-2019 Apache Software Foundation. All Rights Reserved.