Package org.lwjgl.util.spvc
Class SpvcReflectedBuiltinResource
java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<SpvcReflectedBuiltinResource>
org.lwjgl.util.spvc.SpvcReflectedBuiltinResource
- All Implemented Interfaces:
AutoCloseable
,NativeResource
,Pointer
public class SpvcReflectedBuiltinResource
extends Struct<SpvcReflectedBuiltinResource>
implements NativeResource
struct spvc_reflected_builtin_resource {
SpvBuiltIn builtin;
spvc_type_id value_type_id;
{@link SpvcReflectedResource spvc_reflected_resource} resource;
}
-
Nested Class Summary
Nested ClassesNested 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
FieldsModifier 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.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
ConstructorsConstructorDescriptionSpvcReflectedBuiltinResource
(ByteBuffer container) Creates aSpvcReflectedBuiltinResource
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionint
builtin()
builtin
(int value) Sets the specified value to thebuiltin
field.static SpvcReflectedBuiltinResource
calloc()
Returns a newSpvcReflectedBuiltinResource
instance allocated withmemCalloc
.calloc
(int capacity) Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated withmemCalloc
.calloc
(int capacity, MemoryStack stack) Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static SpvcReflectedBuiltinResource
calloc
(MemoryStack stack) Returns a newSpvcReflectedBuiltinResource
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static SpvcReflectedBuiltinResource
create()
Returns a newSpvcReflectedBuiltinResource
instance allocated withBufferUtils
.create
(int capacity) Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated withBufferUtils
.static SpvcReflectedBuiltinResource
create
(long address) Returns a newSpvcReflectedBuiltinResource
instance for the specified memory address.create
(long address, int capacity) Create aSpvcReflectedBuiltinResource.Buffer
instance at the specified memory.static @Nullable SpvcReflectedBuiltinResource
createSafe
(long address) static @Nullable SpvcReflectedBuiltinResource.Buffer
createSafe
(long address, int capacity) static SpvcReflectedBuiltinResource
malloc()
Returns a newSpvcReflectedBuiltinResource
instance allocated withmemAlloc
.malloc
(int capacity) Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated withmemAlloc
.malloc
(int capacity, MemoryStack stack) Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated on the specifiedMemoryStack
.static SpvcReflectedBuiltinResource
malloc
(MemoryStack stack) Returns a newSpvcReflectedBuiltinResource
instance allocated on the specifiedMemoryStack
.static int
nbuiltin
(long struct) Unsafe version ofbuiltin()
.static void
nbuiltin
(long struct, int value) Unsafe version ofbuiltin
.static SpvcReflectedResource
nresource
(long struct) Unsafe version ofresource()
.static void
nresource
(long struct, SpvcReflectedResource value) Unsafe version ofresource
.static int
nvalue_type_id
(long struct) Unsafe version ofvalue_type_id()
.static void
nvalue_type_id
(long struct, int value) Unsafe version ofvalue_type_id
.resource()
resource
(Consumer<SpvcReflectedResource> consumer) Passes theresource
field to the specifiedConsumer
.resource
(SpvcReflectedResource value) Copies the specifiedSpvcReflectedResource
to theresource
field.set
(int builtin, int value_type_id, SpvcReflectedResource resource) Initializes this struct with the specified values.Copies the specified struct data to this struct.int
sizeof()
Returnssizeof(struct)
.static void
validate
(long struct) Validates pointer members that should not beNULL
.int
value_type_id
(int value) Sets the specified value to thevalue_type_id
field.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. -
BUILTIN
public static final int BUILTINThe struct member offsets. -
VALUE_TYPE_ID
public static final int VALUE_TYPE_IDThe struct member offsets. -
RESOURCE
public static final int RESOURCEThe struct member offsets.
-
-
Constructor Details
-
SpvcReflectedBuiltinResource
Creates aSpvcReflectedBuiltinResource
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<SpvcReflectedBuiltinResource>
-
builtin
public int builtin()- Returns:
- the value of the
builtin
field.
-
value_type_id
public int value_type_id()- Returns:
- the value of the
value_type_id
field.
-
resource
- Returns:
- a
SpvcReflectedResource
view of theresource
field.
-
builtin
Sets the specified value to thebuiltin
field. -
value_type_id
Sets the specified value to thevalue_type_id
field. -
resource
Copies the specifiedSpvcReflectedResource
to theresource
field. -
resource
Passes theresource
field to the specifiedConsumer
. -
set
public SpvcReflectedBuiltinResource set(int builtin, int value_type_id, SpvcReflectedResource resource) 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 newSpvcReflectedBuiltinResource
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newSpvcReflectedBuiltinResource
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newSpvcReflectedBuiltinResource
instance allocated withBufferUtils
. -
create
Returns a newSpvcReflectedBuiltinResource
instance for the specified memory address. -
createSafe
-
malloc
Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
Create aSpvcReflectedBuiltinResource.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
-
malloc
Returns a newSpvcReflectedBuiltinResource
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newSpvcReflectedBuiltinResource
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
calloc
Returns a newSpvcReflectedBuiltinResource.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
nbuiltin
public static int nbuiltin(long struct) Unsafe version ofbuiltin()
. -
nvalue_type_id
public static int nvalue_type_id(long struct) Unsafe version ofvalue_type_id()
. -
nresource
Unsafe version ofresource()
. -
nbuiltin
public static void nbuiltin(long struct, int value) Unsafe version ofbuiltin
. -
nvalue_type_id
public static void nvalue_type_id(long struct, int value) Unsafe version ofvalue_type_id
. -
nresource
Unsafe version ofresource
. -
validate
public static void validate(long struct) Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-