Package org.lwjgl.cuda
Class CUDA_HOST_NODE_PARAMS
- All Implemented Interfaces:
AutoCloseable
,NativeResource
,Pointer
Layout
struct CUDA_HOST_NODE_PARAMS {
void (*fn
) (void *userData);
void * userData;
}
-
Nested Class Summary
Nested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidation
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
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 size in bytes.static final int
The struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorDescriptionCUDA_HOST_NODE_PARAMS
(ByteBuffer container) Creates aCUDA_HOST_NODE_PARAMS
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionstatic CUDA_HOST_NODE_PARAMS
calloc()
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated withmemCalloc
.static CUDA_HOST_NODE_PARAMS.Buffer
calloc
(int capacity) Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated withmemCalloc
.static CUDA_HOST_NODE_PARAMS.Buffer
calloc
(int capacity, MemoryStack stack) Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static CUDA_HOST_NODE_PARAMS
calloc
(MemoryStack stack) Returns a newCUDA_HOST_NODE_PARAMS
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static CUDA_HOST_NODE_PARAMS
Deprecated.static CUDA_HOST_NODE_PARAMS.Buffer
callocStack
(int capacity) Deprecated.static CUDA_HOST_NODE_PARAMS.Buffer
callocStack
(int capacity, MemoryStack stack) Deprecated.static CUDA_HOST_NODE_PARAMS
callocStack
(MemoryStack stack) Deprecated.static CUDA_HOST_NODE_PARAMS
create()
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated withBufferUtils
.static CUDA_HOST_NODE_PARAMS.Buffer
create
(int capacity) Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated withBufferUtils
.static CUDA_HOST_NODE_PARAMS
create
(long address) Returns a newCUDA_HOST_NODE_PARAMS
instance for the specified memory address.static CUDA_HOST_NODE_PARAMS.Buffer
create
(long address, int capacity) Create aCUDA_HOST_NODE_PARAMS.Buffer
instance at the specified memory.static CUDA_HOST_NODE_PARAMS
createSafe
(long address) static CUDA_HOST_NODE_PARAMS.Buffer
createSafe
(long address, int capacity) fn()
Sets the specified value to thefn
field.static CUDA_HOST_NODE_PARAMS
malloc()
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated withmemAlloc
.static CUDA_HOST_NODE_PARAMS.Buffer
malloc
(int capacity) Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated withmemAlloc
.static CUDA_HOST_NODE_PARAMS.Buffer
malloc
(int capacity, MemoryStack stack) Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated on the specifiedMemoryStack
.static CUDA_HOST_NODE_PARAMS
malloc
(MemoryStack stack) Returns a newCUDA_HOST_NODE_PARAMS
instance allocated on the specifiedMemoryStack
.static CUDA_HOST_NODE_PARAMS
Deprecated.static CUDA_HOST_NODE_PARAMS.Buffer
mallocStack
(int capacity) Deprecated.static CUDA_HOST_NODE_PARAMS.Buffer
mallocStack
(int capacity, MemoryStack stack) Deprecated.static CUDA_HOST_NODE_PARAMS
mallocStack
(MemoryStack stack) Deprecated.static CUhostFn
nfn
(long struct) Unsafe version offn()
.static void
Unsafe version offn
.static long
nuserData
(long struct) Unsafe version ofuserData()
.static void
nuserData
(long struct, long value) Unsafe version ofuserData
.set
(CUDA_HOST_NODE_PARAMS src) Copies the specified struct data to this struct.Initializes this struct with the specified values.int
sizeof()
Returnssizeof(struct)
.long
userData()
userData
(long value) Sets the specified value to theuserData
field.static void
validate
(long struct) Validates pointer members that should not beNULL
.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. -
FN
public static final int FNThe struct member offsets. -
USERDATA
public static final int USERDATAThe struct member offsets.
-
-
Constructor Details
-
CUDA_HOST_NODE_PARAMS
Creates aCUDA_HOST_NODE_PARAMS
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()Description copied from class:Struct
Returnssizeof(struct)
.- Specified by:
sizeof
in classStruct<CUDA_HOST_NODE_PARAMS>
-
fn
- Returns:
- the value of the
fn
field.
-
userData
public long userData()- Returns:
- the value of the
userData
field.
-
fn
Sets the specified value to thefn
field. -
userData
Sets the specified value to theuserData
field. -
set
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
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated withBufferUtils
. -
create
Returns a newCUDA_HOST_NODE_PARAMS
instance for the specified memory address. -
createSafe
-
malloc
Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
Create aCUDA_HOST_NODE_PARAMS.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
-
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
malloc
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newCUDA_HOST_NODE_PARAMS
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
calloc
Returns a newCUDA_HOST_NODE_PARAMS.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
nfn
Unsafe version offn()
. -
nuserData
public static long nuserData(long struct) Unsafe version ofuserData()
. -
nfn
Unsafe version offn
. -
nuserData
public static void nuserData(long struct, long value) Unsafe version ofuserData
. -
validate
public static void validate(long struct) Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-