Package org.lwjgl.sdl
Class SDL_AsyncIOOutcome
- All Implemented Interfaces:
AutoCloseable,NativeResource,Pointer
struct SDL_AsyncIOOutcome {
SDL_AsyncIO * asyncio;
SDL_AsyncIOTaskType type;
SDL_AsyncIOResult result;
void * buffer;
Uint64 offset;
Uint64 bytes_requested;
Uint64 bytes_transferred;
void * userdata;
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.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 member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.static final intThe struct member offsets.static final intThe struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionSDL_AsyncIOOutcome(ByteBuffer container) Creates aSDL_AsyncIOOutcomeinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionlongasyncio()buffer(int capacity) longlongstatic SDL_AsyncIOOutcomecalloc()Returns a newSDL_AsyncIOOutcomeinstance allocated withmemCalloc.static SDL_AsyncIOOutcome.Buffercalloc(int capacity) Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated withmemCalloc.static SDL_AsyncIOOutcome.Buffercalloc(int capacity, MemoryStack stack) Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static SDL_AsyncIOOutcomecalloc(MemoryStack stack) Returns a newSDL_AsyncIOOutcomeinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static SDL_AsyncIOOutcomecreate()Returns a newSDL_AsyncIOOutcomeinstance allocated withBufferUtils.static SDL_AsyncIOOutcome.Buffercreate(int capacity) Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated withBufferUtils.static SDL_AsyncIOOutcomecreate(long address) Returns a newSDL_AsyncIOOutcomeinstance for the specified memory address.static SDL_AsyncIOOutcome.Buffercreate(long address, int capacity) Create aSDL_AsyncIOOutcome.Bufferinstance at the specified memory.static @Nullable SDL_AsyncIOOutcomecreateSafe(long address) static @Nullable SDL_AsyncIOOutcome.BuffercreateSafe(long address, int capacity) static SDL_AsyncIOOutcomemalloc()Returns a newSDL_AsyncIOOutcomeinstance allocated withmemAlloc.static SDL_AsyncIOOutcome.Buffermalloc(int capacity) Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated withmemAlloc.static SDL_AsyncIOOutcome.Buffermalloc(int capacity, MemoryStack stack) Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated on the specifiedMemoryStack.static SDL_AsyncIOOutcomemalloc(MemoryStack stack) Returns a newSDL_AsyncIOOutcomeinstance allocated on the specifiedMemoryStack.static longnasyncio(long struct) Unsafe version ofasyncio().static ByteBuffernbuffer(long struct, int capacity) Unsafe version ofbuffer.static longnbytes_requested(long struct) Unsafe version ofbytes_requested().static longnbytes_transferred(long struct) Unsafe version ofbytes_transferred().static longnoffset(long struct) Unsafe version ofoffset().static intnresult(long struct) Unsafe version ofresult().static intntype(long struct) Unsafe version oftype().static longnuserdata(long struct) Unsafe version ofuserdata().longoffset()intresult()intsizeof()Returnssizeof(struct).inttype()longuserdata()Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toStringMethods 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. -
ASYNCIO
public static final int ASYNCIOThe struct member offsets. -
TYPE
public static final int TYPEThe struct member offsets. -
RESULT
public static final int RESULTThe struct member offsets. -
BUFFER
public static final int BUFFERThe struct member offsets. -
OFFSET
public static final int OFFSETThe struct member offsets. -
BYTES_REQUESTED
public static final int BYTES_REQUESTEDThe struct member offsets. -
BYTES_TRANSFERRED
public static final int BYTES_TRANSFERREDThe struct member offsets. -
USERDATA
public static final int USERDATAThe struct member offsets.
-
-
Constructor Details
-
SDL_AsyncIOOutcome
Creates aSDL_AsyncIOOutcomeinstance 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<SDL_AsyncIOOutcome>
-
asyncio
public long asyncio()- Returns:
- the value of the
asynciofield.
-
type
public int type()- Returns:
- the value of the
typefield.
-
result
public int result()- Returns:
- the value of the
resultfield.
-
buffer
- Returns:
- a
ByteBufferview of the data pointed to by thebufferfield.
-
offset
public long offset()- Returns:
- the value of the
offsetfield.
-
bytes_requested
public long bytes_requested()- Returns:
- the value of the
bytes_requestedfield.
-
bytes_transferred
public long bytes_transferred()- Returns:
- the value of the
bytes_transferredfield.
-
userdata
public long userdata()- Returns:
- the value of the
userdatafield.
-
malloc
Returns a newSDL_AsyncIOOutcomeinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newSDL_AsyncIOOutcomeinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newSDL_AsyncIOOutcomeinstance allocated withBufferUtils. -
create
Returns a newSDL_AsyncIOOutcomeinstance for the specified memory address. -
createSafe
-
malloc
Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aSDL_AsyncIOOutcome.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
malloc
Returns a newSDL_AsyncIOOutcomeinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newSDL_AsyncIOOutcomeinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newSDL_AsyncIOOutcome.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
nasyncio
public static long nasyncio(long struct) Unsafe version ofasyncio(). -
ntype
public static int ntype(long struct) Unsafe version oftype(). -
nresult
public static int nresult(long struct) Unsafe version ofresult(). -
nbuffer
Unsafe version ofbuffer. -
noffset
public static long noffset(long struct) Unsafe version ofoffset(). -
nbytes_requested
public static long nbytes_requested(long struct) Unsafe version ofbytes_requested(). -
nbytes_transferred
public static long nbytes_transferred(long struct) Unsafe version ofbytes_transferred(). -
nuserdata
public static long nuserdata(long struct) Unsafe version ofuserdata().
-