Class NkBufferMarker

  • All Implemented Interfaces:

    public class NkBufferMarker
    extends Struct


     struct nk_buffer_marker {
         int active;
         nk_size offset;
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.

        The struct member offsets.
    • Constructor Detail

      • NkBufferMarker

        public NkBufferMarker​(java.nio.ByteBuffer container)
        Creates a NkBufferMarker 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 Detail

      • sizeof

        public int sizeof()
        Description copied from class: Struct
        Returns sizeof(struct).
        Specified by:
        sizeof in class Struct
      • active

        public int active()
        Returns the value of the active field.
      • offset

        public long offset()
        Returns the value of the offset field.
      • create

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

        public static NkBufferMarker createSafe​(long address)
        Like create, but returns null if address is NULL.
      • create

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

        public static NkBufferMarker.Buffer createSafe​(long address,
                                                       int capacity)
        Like create, but returns null if address is NULL.
      • nactive

        public static int nactive​(long struct)
        Unsafe version of active().
      • noffset

        public static long noffset​(long struct)
        Unsafe version of offset().