Class ValueBuffer

java.lang.Object
net.royalur.lut.buffer.ValueBuffer
Direct Known Subclasses:
FloatValueBuffer, IntValueBuffer

public abstract class ValueBuffer extends Object
Stores binary values and provides efficient methods to manipulate it.
  • Constructor Details

    • ValueBuffer

      public ValueBuffer(ValueType type, int capacity)
  • Method Details

    • getType

      public ValueType getType()
    • getCapacity

      public int getCapacity()
    • set

      public abstract long set(int index, long value)
    • set

      public abstract int set(int index, int value)
    • set

      public abstract short set(int index, short value)
    • set

      public abstract byte set(int index, byte value)
    • set

      public abstract double set(int index, double value)
    • set

      public abstract float set(int index, float value)
    • getLong

      public abstract long getLong(int index)
    • getInt

      public abstract int getInt(int index)
    • getShort

      public abstract short getShort(int index)
    • getByte

      public abstract byte getByte(int index)
    • getDouble

      public abstract double getDouble(int index)
    • getFloat

      public abstract float getFloat(int index)
    • moveIntoPlace

      public abstract void moveIntoPlace(int index, int targetIndex)
      Moves the value to targetIndex, and shifts all values in between.
    • writeContents

      public abstract void writeContents(DataSink output, int startIndex, int endIndex) throws IOException
      Throws:
      IOException
    • writeContents

      public void writeContents(DataSink output) throws IOException
      Throws:
      IOException
    • readContents

      public abstract void readContents(DataSource input, int startIndex, int endIndex) throws IOException
      Throws:
      IOException
    • readContents

      public void readContents(DataSource input) throws IOException
      Throws:
      IOException