Package org.lwjgl.nuklear
Class NkMemory
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.nuklear.NkMemory
-
- All Implemented Interfaces:
org.lwjgl.system.Pointer
public class NkMemory extends org.lwjgl.system.StructLayout
struct nk_memory { void * ptr; nk_size size; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classNkMemory.BufferAn array ofNkMemorystructs.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static NkMemorycreate(long address)Returns a newNkMemoryinstance for the specified memory address.static NkMemory.Buffercreate(long address, int capacity)Create aNkMemory.Bufferinstance at the specified memory.static NkMemorycreateSafe(long address)static NkMemory.BuffercreateSafe(long address, int capacity)static java.nio.ByteBuffernptr(long struct)Unsafe version ofptr.static longnsize(long struct)Unsafe version ofsize().java.nio.ByteBufferptr()Returns aByteBufferview of the data pointed to by theptrfield.longsize()Returns the value of thesizefield.intsizeof()
-
-
-
Constructor Detail
-
NkMemory
public NkMemory(java.nio.ByteBuffer container)
Creates aNkMemoryinstance at the current position of the specifiedByteBuffercontainer. 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()
- Specified by:
sizeofin classorg.lwjgl.system.Struct
-
ptr
@Nullable public java.nio.ByteBuffer ptr()
Returns aByteBufferview of the data pointed to by theptrfield.
-
size
public long size()
Returns the value of thesizefield.
-
create
public static NkMemory create(long address)
Returns a newNkMemoryinstance for the specified memory address.
-
createSafe
@Nullable public static NkMemory createSafe(long address)
-
create
public static NkMemory.Buffer create(long address, int capacity)
Create aNkMemory.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static NkMemory.Buffer createSafe(long address, int capacity)
-
nptr
@Nullable public static java.nio.ByteBuffer nptr(long struct)
Unsafe version ofptr.
-
nsize
public static long nsize(long struct)
Unsafe version ofsize().
-
-