Package com.qfs.index

Interface IIntegerArray

All Known Subinterfaces:
IIntegerArrayTransaction, IIntegerArrayVersion, ISquashableIntegerArrayVersion, IWritableIntegerArray
All Known Implementing Classes:
AIntegerArray, ChunkedIntegerArray, IntegerArray, IntegerArrayTransaction, IntegerArrayVersion

public interface IIntegerArray
Interface for an integer array.
Author:
ActiveViam
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
    The default empty value.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the value that marks an empty spot in this array.
    int
    getValue(int index)
    Returns the value stored at the given index, or the empty value if there is no value stored there.
    int
    Returns the size of this array.
    void
    transferValues(int[] indexes, int[] valuesBuffer, int numIndexes)
    Transfers the values associated with the given indexes into the given buffer.
  • Field Details

    • DEFAULT_EMPTY_VALUE

      static final int DEFAULT_EMPTY_VALUE
      The default empty value.

      We cannot take a negative value since we sometimes store them for above components.

      See Also:
  • Method Details

    • getValue

      int getValue(int index)
      Returns the value stored at the given index, or the empty value if there is no value stored there.
      Parameters:
      index - the index
      Returns:
      the value stored at that index
    • transferValues

      void transferValues(int[] indexes, int[] valuesBuffer, int numIndexes)
      Transfers the values associated with the given indexes into the given buffer.
      Parameters:
      indexes - the indexes from which the values should be transferred
      valuesBuffer - the buffer into which the values will be transferred
      numIndexes - the number of indexes to transfer the values from
    • size

      int size()
      Returns the size of this array.
      Returns:
      the size
    • getEmptyValue

      int getEmptyValue()
      Returns the value that marks an empty spot in this array.
      Returns:
      the value that marks an empty spot