Overview | Package | Class | Use | Tree | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.lucene.util.packed
Interface PackedInts.Decoder

Enclosing class:
  PackedInts

    public static interface PackedInts.Decoder

A decoder for packed integers.

Method Summary
`int` | `byteBlockCount()` The minimum number of byte blocks to encode in a single iteration, when using byte encoding.
`int` | `byteValueCount()` The number of values that can be stored in `byteBlockCount()` byte blocks.
`void` | `decode(byte[] blocks, int blocksOffset, int[] values, int valuesOffset, int iterations)` Read `8 * iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.
`void` | `decode(byte[] blocks, int blocksOffset, long[] values, int valuesOffset, int iterations)` Read `8 * iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.
`void` | `decode(long[] blocks, int blocksOffset, int[] values, int valuesOffset, int iterations)` Read `iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.
`void` | `decode(long[] blocks, int blocksOffset, long[] values, int valuesOffset, int iterations)` Read `iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.
`int` | `longBlockCount()` The minimum number of long blocks to encode in a single iteration, when using long encoding.
`int` | `longValueCount()` The number of values that can be stored in `longBlockCount()` long blocks.

Method Detail

### longBlockCount

    int longBlockCount()

  The minimum number of long blocks to encode in a single iteration, when using long encoding.

### longValueCount

    int longValueCount()

  The number of values that can be stored in `longBlockCount()` long blocks.

### byteBlockCount

    int byteBlockCount()

  The minimum number of byte blocks to encode in a single iteration, when using byte encoding.

### byteValueCount

    int byteValueCount()

  The number of values that can be stored in `byteBlockCount()` byte blocks.

### decode

    void decode(long[] blocks,
                int blocksOffset,
                long[] values,
                int valuesOffset,
                int iterations)

  Read `iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.

  Parameters:
    `blocks` - the long blocks that hold packed integer values
    `blocksOffset` - the offset where to start reading blocks
    `values` - the values buffer
    `valuesOffset` - the offset where to start writing values
    `iterations` - controls how much data to decode

### decode

    void decode(byte[] blocks,
                int blocksOffset,
                long[] values,
                int valuesOffset,
                int iterations)

  Read `8 * iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.

  Parameters:
    `blocks` - the long blocks that hold packed integer values
    `blocksOffset` - the offset where to start reading blocks
    `values` - the values buffer
    `valuesOffset` - the offset where to start writing values
    `iterations` - controls how much data to decode

### decode

    void decode(long[] blocks,
                int blocksOffset,
                int[] values,
                int valuesOffset,
                int iterations)

  Read `iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.

  Parameters:
    `blocks` - the long blocks that hold packed integer values
    `blocksOffset` - the offset where to start reading blocks
    `values` - the values buffer
    `valuesOffset` - the offset where to start writing values
    `iterations` - controls how much data to decode

### decode

    void decode(byte[] blocks,
                int blocksOffset,
                int[] values,
                int valuesOffset,
                int iterations)

  Read `8 * iterations * blockCount()` blocks from `blocks`, decode them and write `iterations * valueCount()` values into `values`.

  Parameters:
    `blocks` - the long blocks that hold packed integer values
    `blocksOffset` - the offset where to start reading blocks
    `values` - the values buffer
    `valuesOffset` - the offset where to start writing values
    `iterations` - controls how much data to decode

Overview | Package | Class | Use | Tree | Deprecated | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

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