Class NkAllocator

All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer

public class NkAllocator extends Struct<NkAllocator> implements NativeResource

Layout


 struct nk_allocator {
     nk_handle userdata;
     nk_plugin_alloc alloc;
     nk_plugin_free mfree;
 }
  • Field Details

    • SIZEOF

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

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

      public static final int USERDATA
      The struct member offsets.
    • ALLOC

      public static final int ALLOC
      The struct member offsets.
    • MFREE

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

    • NkAllocator

      public NkAllocator(ByteBuffer container)
      Creates a NkAllocator 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