Class LibDivideS16BranchFree

java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<LibDivideS16BranchFree>
org.lwjgl.util.libdivide.LibDivideS16BranchFree
All Implemented Interfaces:
AutoCloseable, org.lwjgl.system.NativeResource, org.lwjgl.system.Pointer

public class LibDivideS16BranchFree extends org.lwjgl.system.Struct<LibDivideS16BranchFree> implements org.lwjgl.system.NativeResource

Layout


 struct libdivide_s16_branchfree_t {
     int16_t magic;
     uint8_t more;
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • MAGIC

      public static final int MAGIC
      The struct member offsets.
    • MORE

      public static final int MORE
      The struct member offsets.
  • Constructor Details

    • LibDivideS16BranchFree

      public LibDivideS16BranchFree(ByteBuffer container)
      Creates a LibDivideS16BranchFree instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

      The created instance holds a strong reference to the container object.

  • Method Details

    • sizeof

      public int sizeof()
      Specified by:
      sizeof in class org.lwjgl.system.Struct<LibDivideS16BranchFree>
    • magic

      public short magic()
      Returns:
      the value of the magic field.
    • more

      public byte more()
      Returns:
      the value of the more field.
    • magic

      public LibDivideS16BranchFree magic(short value)
      Sets the specified value to the magic field.
    • more

      public LibDivideS16BranchFree more(byte value)
      Sets the specified value to the more field.
    • set

      public LibDivideS16BranchFree set(short magic, byte more)
      Initializes this struct with the specified values.
    • set

      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

      public static LibDivideS16BranchFree malloc()
      Returns a new LibDivideS16BranchFree instance allocated with memAlloc. The instance must be explicitly freed.
    • calloc

      public static LibDivideS16BranchFree calloc()
      Returns a new LibDivideS16BranchFree instance allocated with memCalloc. The instance must be explicitly freed.
    • create

      public static LibDivideS16BranchFree create()
      Returns a new LibDivideS16BranchFree instance allocated with BufferUtils.
    • create

      public static LibDivideS16BranchFree create(long address)
      Returns a new LibDivideS16BranchFree instance for the specified memory address.
    • createSafe

      public static @Nullable LibDivideS16BranchFree createSafe(long address)
      Like create, but returns null if address is NULL.
    • malloc

      public static LibDivideS16BranchFree.Buffer malloc(int capacity)
      Returns a new LibDivideS16BranchFree.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • calloc

      public static LibDivideS16BranchFree.Buffer calloc(int capacity)
      Returns a new LibDivideS16BranchFree.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • create

      public static LibDivideS16BranchFree.Buffer create(int capacity)
      Returns a new LibDivideS16BranchFree.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

      public static LibDivideS16BranchFree.Buffer create(long address, int capacity)
      Create a LibDivideS16BranchFree.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

      public static @Nullable LibDivideS16BranchFree.Buffer createSafe(long address, int capacity)
      Like create, but returns null if address is NULL.
    • malloc

      public static LibDivideS16BranchFree malloc(org.lwjgl.system.MemoryStack stack)
      Returns a new LibDivideS16BranchFree instance allocated on the specified MemoryStack.
      Parameters:
      stack - the stack from which to allocate
    • calloc

      public static LibDivideS16BranchFree calloc(org.lwjgl.system.MemoryStack stack)
      Returns a new LibDivideS16BranchFree instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      stack - the stack from which to allocate
    • malloc

      public static LibDivideS16BranchFree.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new LibDivideS16BranchFree.Buffer instance allocated on the specified MemoryStack.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • calloc

      public static LibDivideS16BranchFree.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new LibDivideS16BranchFree.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • nmagic

      public static short nmagic(long struct)
      Unsafe version of magic().
    • nmore

      public static byte nmore(long struct)
      Unsafe version of more().
    • nmagic

      public static void nmagic(long struct, short value)
      Unsafe version of magic.
    • nmore

      public static void nmore(long struct, byte value)
      Unsafe version of more.