Class NFDOpenDialogArgs

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

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

Layout


 struct nfdopendialogu8args_t {
     nfdfilteritem_t const * filterList;
     nfdfiltersize_t filterCount;
     nfdchar_t const * defaultPath;
     nfdwindowhandle_t parentWindow;
 }
  • Field Details

    • SIZEOF

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

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

      public static final int FILTERLIST
      The struct member offsets.
    • FILTERCOUNT

      public static final int FILTERCOUNT
      The struct member offsets.
    • DEFAULTPATH

      public static final int DEFAULTPATH
      The struct member offsets.
    • PARENTWINDOW

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

    • NFDOpenDialogArgs

      public NFDOpenDialogArgs(ByteBuffer container)
      Creates a NFDOpenDialogArgs 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<NFDOpenDialogArgs>
    • filterList

      public @Nullable NFDFilterItem.Buffer filterList()
      Returns:
      a NFDFilterItem.Buffer view of the struct array pointed to by the filterList field.
    • filterCount

      public int filterCount()
      Returns:
      the value of the filterCount field.
    • defaultPath

      public @Nullable ByteBuffer defaultPath()
      Returns:
      a ByteBuffer view of the null-terminated string pointed to by the defaultPath field.
    • defaultPathString

      public @Nullable String defaultPathString()
      Returns:
      the null-terminated string pointed to by the defaultPath field.
    • parentWindow

      public NFDWindowHandle parentWindow()
      Returns:
      a NFDWindowHandle view of the parentWindow field.
    • filterList

      public NFDOpenDialogArgs filterList(@Nullable NFDFilterItem.Buffer value)
      Sets the address of the specified NFDFilterItem.Buffer to the filterList field.
    • defaultPath

      public NFDOpenDialogArgs defaultPath(@Nullable ByteBuffer value)
      Sets the address of the specified encoded string to the defaultPath field.
    • parentWindow

      public NFDOpenDialogArgs parentWindow(NFDWindowHandle value)
      Copies the specified NFDWindowHandle to the parentWindow field.
    • parentWindow

      public NFDOpenDialogArgs parentWindow(Consumer<NFDWindowHandle> consumer)
      Passes the parentWindow field to the specified Consumer.
    • set

      public NFDOpenDialogArgs set(@Nullable NFDFilterItem.Buffer filterList, @Nullable ByteBuffer defaultPath, NFDWindowHandle parentWindow)
      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 NFDOpenDialogArgs malloc()
      Returns a new NFDOpenDialogArgs instance allocated with memAlloc. The instance must be explicitly freed.
    • calloc

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

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

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

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

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

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

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

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

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

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

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

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

      public static NFDOpenDialogArgs.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new NFDOpenDialogArgs.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
    • nfilterList

      public static @Nullable NFDFilterItem.Buffer nfilterList(long struct)
      Unsafe version of filterList().
    • nfilterCount

      public static int nfilterCount(long struct)
      Unsafe version of filterCount().
    • ndefaultPath

      public static @Nullable ByteBuffer ndefaultPath(long struct)
      Unsafe version of defaultPath().
    • ndefaultPathString

      public static @Nullable String ndefaultPathString(long struct)
      Unsafe version of defaultPathString().
    • nparentWindow

      public static NFDWindowHandle nparentWindow(long struct)
      Unsafe version of parentWindow().
    • nfilterList

      public static void nfilterList(long struct, @Nullable NFDFilterItem.Buffer value)
      Unsafe version of filterList.
    • nfilterCount

      public static void nfilterCount(long struct, int value)
      Sets the specified value to the filterCount field of the specified struct.
    • ndefaultPath

      public static void ndefaultPath(long struct, @Nullable ByteBuffer value)
      Unsafe version of defaultPath.
    • nparentWindow

      public static void nparentWindow(long struct, NFDWindowHandle value)
      Unsafe version of parentWindow.
    • validate

      public static void validate(long struct)
      Validates pointer members that should not be NULL.
      Parameters:
      struct - the struct to validate