Class ExrMemoryPoolCreateInfo
- All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer
public class ExrMemoryPoolCreateInfo
extends Struct<ExrMemoryPoolCreateInfo>
implements NativeResource
struct ExrMemoryPoolCreateInfo {
size_t initial_size;
size_t max_size;
uint32_t flags;
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class Struct
Struct.StructValidationNested classes/interfaces inherited from interface Pointer
Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.Fields inherited from interface Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionExrMemoryPoolCreateInfo(ByteBuffer container) Creates aExrMemoryPoolCreateInfoinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionstatic ExrMemoryPoolCreateInfocalloc()Returns a newExrMemoryPoolCreateInfoinstance allocated withmemCalloc.calloc(int capacity) Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated withmemCalloc.calloc(int capacity, MemoryStack stack) Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static ExrMemoryPoolCreateInfocalloc(MemoryStack stack) Returns a newExrMemoryPoolCreateInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static ExrMemoryPoolCreateInfocreate()Returns a newExrMemoryPoolCreateInfoinstance allocated withBufferUtils.create(int capacity) Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated withBufferUtils.static ExrMemoryPoolCreateInfocreate(long address) Returns a newExrMemoryPoolCreateInfoinstance for the specified memory address.create(long address, int capacity) Create aExrMemoryPoolCreateInfo.Bufferinstance at the specified memory.static @Nullable ExrMemoryPoolCreateInfocreateSafe(long address) static @Nullable ExrMemoryPoolCreateInfo.BuffercreateSafe(long address, int capacity) intflags()flags(int value) Sets the specified value to theflagsfield.longinitial_size(long value) Sets the specified value to theinitial_sizefield.static ExrMemoryPoolCreateInfomalloc()Returns a newExrMemoryPoolCreateInfoinstance allocated withmemAlloc.malloc(int capacity) Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated withmemAlloc.malloc(int capacity, MemoryStack stack) Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated on the specifiedMemoryStack.static ExrMemoryPoolCreateInfomalloc(MemoryStack stack) Returns a newExrMemoryPoolCreateInfoinstance allocated on the specifiedMemoryStack.longmax_size()max_size(long value) Sets the specified value to themax_sizefield.static intnflags(long struct) Unsafe version offlags().static voidnflags(long struct, int value) Unsafe version offlags.static longninitial_size(long struct) Unsafe version ofinitial_size().static voidninitial_size(long struct, long value) Unsafe version ofinitial_size.static longnmax_size(long struct) Unsafe version ofmax_size().static voidnmax_size(long struct, long value) Unsafe version ofmax_size.set(long initial_size, long max_size, int flags) Initializes this struct with the specified values.Copies the specified struct data to this struct.intsizeof()Returnssizeof(struct).Methods inherited from class Pointer.Default
address, equals, hashCode, toStringMethods inherited from interface 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. -
INITIAL_SIZE
public static final int INITIAL_SIZEThe struct member offsets. -
MAX_SIZE
public static final int MAX_SIZEThe struct member offsets. -
FLAGS
public static final int FLAGSThe struct member offsets.
-
-
Constructor Details
-
ExrMemoryPoolCreateInfo
Creates aExrMemoryPoolCreateInfoinstance 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 Details
-
sizeof
public int sizeof()Description copied from class:StructReturnssizeof(struct).- Specified by:
sizeofin classStruct<ExrMemoryPoolCreateInfo>
-
initial_size
- Returns:
- the value of the
initial_sizefield.
-
max_size
- Returns:
- the value of the
max_sizefield.
-
flags
- Returns:
- the value of the
flagsfield.
-
initial_size
Sets the specified value to theinitial_sizefield. -
max_size
Sets the specified value to themax_sizefield. -
flags
Sets the specified value to theflagsfield. -
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 newExrMemoryPoolCreateInfoinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newExrMemoryPoolCreateInfoinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newExrMemoryPoolCreateInfoinstance allocated withBufferUtils. -
create
Returns a newExrMemoryPoolCreateInfoinstance for the specified memory address. -
createSafe
-
malloc
Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aExrMemoryPoolCreateInfo.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
malloc
Returns a newExrMemoryPoolCreateInfoinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newExrMemoryPoolCreateInfoinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newExrMemoryPoolCreateInfo.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
ninitial_size
public static long ninitial_size(long struct) Unsafe version ofinitial_size(). -
nmax_size
public static long nmax_size(long struct) Unsafe version ofmax_size(). -
nflags
public static int nflags(long struct) Unsafe version offlags(). -
ninitial_size
public static void ninitial_size(long struct, long value) Unsafe version ofinitial_size. -
nmax_size
public static void nmax_size(long struct, long value) Unsafe version ofmax_size. -
nflags
public static void nflags(long struct, int value) Unsafe version offlags.
-