Class BitUtil

java.lang.Object
io.github.jbellis.jvector.util.BitUtil

public final class BitUtil extends Object
A variety of high efficiency bit twiddling routines and encoders for primitives.
  • Field Details

    • VH_BE_SHORT

      @Deprecated public static final VarHandle VH_BE_SHORT
      Deprecated.
      Better use little endian unless it is needed for backwards compatibility.
      A VarHandle to read/write big endian short from a byte array. Shape: short vh.get(byte[] arr, int ofs) and void vh.set(byte[] arr, int ofs, short val)
    • VH_BE_INT

      @Deprecated public static final VarHandle VH_BE_INT
      Deprecated.
      Better use little endian unless it is needed for backwards compatibility.
      A VarHandle to read/write big endian int from a byte array. Shape: int vh.get(byte[] arr, int ofs) and void vh.set(byte[] arr, int ofs, int val)
    • VH_BE_LONG

      @Deprecated public static final VarHandle VH_BE_LONG
      Deprecated.
      Better use little endian unless it is needed for backwards compatibility.
      A VarHandle to read/write big endian long from a byte array. Shape: long vh.get(byte[] arr, int ofs) and void vh.set(byte[] arr, int ofs, long val)
    • VH_BE_FLOAT

      @Deprecated public static final VarHandle VH_BE_FLOAT
      Deprecated.
      Better use little endian unless it is needed for backwards compatibility.
      A VarHandle to read/write big endian float from a byte array. Shape: float vh.get(byte[] arr, int ofs) and void vh.set(byte[] arr, int ofs, float val)
    • VH_BE_DOUBLE

      @Deprecated public static final VarHandle VH_BE_DOUBLE
      Deprecated.
      Better use little endian unless it is needed for backwards compatibility.
      A VarHandle to read/write big endian double from a byte array. Shape: double vh.get(byte[] arr, int ofs) and void vh.set(byte[] arr, int ofs, double val)