Package org.lwjgl.system.windows
Class DATA_BLOB
java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<DATA_BLOB>
org.lwjgl.system.windows.DATA_BLOB
- All Implemented Interfaces:
AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class DATA_BLOB
extends org.lwjgl.system.Struct<DATA_BLOB>
implements org.lwjgl.system.NativeResource
-
Nested Class Summary
Nested classes/interfaces inherited from class org.lwjgl.system.Struct
org.lwjgl.system.Struct.StructValidation
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
org.lwjgl.system.Pointer.Default
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
The struct alignment in bytes.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorDescriptionDATA_BLOB
(ByteBuffer container) Creates aDATA_BLOB
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionstatic DATA_BLOB
calloc()
Returns a newDATA_BLOB
instance allocated withmemCalloc
.static DATA_BLOB.Buffer
calloc
(int capacity) Returns a newDATA_BLOB.Buffer
instance allocated withmemCalloc
.static DATA_BLOB.Buffer
calloc
(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newDATA_BLOB.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static DATA_BLOB
calloc
(org.lwjgl.system.MemoryStack stack) Returns a newDATA_BLOB
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.int
cbData()
the count, in bytes, of datastatic DATA_BLOB
create()
Returns a newDATA_BLOB
instance allocated withBufferUtils
.static DATA_BLOB.Buffer
create
(int capacity) Returns a newDATA_BLOB.Buffer
instance allocated withBufferUtils
.static DATA_BLOB
create
(long address) Returns a newDATA_BLOB
instance for the specified memory address.static DATA_BLOB.Buffer
create
(long address, int capacity) Create aDATA_BLOB.Buffer
instance at the specified memory.static DATA_BLOB
createSafe
(long address) static DATA_BLOB.Buffer
createSafe
(long address, int capacity) static DATA_BLOB
malloc()
Returns a newDATA_BLOB
instance allocated withmemAlloc
.static DATA_BLOB.Buffer
malloc
(int capacity) Returns a newDATA_BLOB.Buffer
instance allocated withmemAlloc
.static DATA_BLOB.Buffer
malloc
(int capacity, org.lwjgl.system.MemoryStack stack) Returns a newDATA_BLOB.Buffer
instance allocated on the specifiedMemoryStack
.static DATA_BLOB
malloc
(org.lwjgl.system.MemoryStack stack) Returns a newDATA_BLOB
instance allocated on the specifiedMemoryStack
.static int
ncbData
(long struct) Unsafe version ofcbData()
.static void
ncbData
(long struct, int value) Sets the specified value to thecbData
field of the specifiedstruct
.static ByteBuffer
npbData
(long struct) Unsafe version ofpbData
.static void
npbData
(long struct, ByteBuffer value) Unsafe version ofpbData
.pbData()
a pointer to the data bufferpbData
(ByteBuffer value) Sets the address of the specifiedByteBuffer
to thepbData()
field.Copies the specified struct data to this struct.int
sizeof()
static void
validate
(long struct) Validates pointer members that should not beNULL
.Methods inherited from class org.lwjgl.system.Struct
clear, free, isNull, validate
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
Methods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
CBDATA
public static final int CBDATAThe struct member offsets. -
PBDATA
public static final int PBDATAThe struct member offsets.
-
-
Constructor Details
-
DATA_BLOB
Creates aDATA_BLOB
instance at the current position of the specifiedByteBuffer
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 classorg.lwjgl.system.Struct<DATA_BLOB>
-
cbData
public int cbData()the count, in bytes, of data -
pbData
a pointer to the data buffer -
pbData
Sets the address of the specifiedByteBuffer
to thepbData()
field. -
set
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
Returns a newDATA_BLOB
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newDATA_BLOB
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newDATA_BLOB
instance allocated withBufferUtils
. -
create
Returns a newDATA_BLOB
instance for the specified memory address. -
createSafe
-
malloc
Returns a newDATA_BLOB.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
Returns a newDATA_BLOB.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
Returns a newDATA_BLOB.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
Create aDATA_BLOB.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
-
malloc
Returns a newDATA_BLOB
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newDATA_BLOB
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
Returns a newDATA_BLOB.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
calloc
Returns a newDATA_BLOB.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
ncbData
public static int ncbData(long struct) Unsafe version ofcbData()
. -
npbData
Unsafe version ofpbData
. -
ncbData
public static void ncbData(long struct, int value) Sets the specified value to thecbData
field of the specifiedstruct
. -
npbData
Unsafe version ofpbData
. -
validate
public static void validate(long struct) Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-