Package org.lwjgl.util.zstd
Class ZSTDOutBuffer
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.util.zstd.ZSTDOutBuffer
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class ZSTDOutBuffer extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classZSTDOutBuffer.BufferAn array ofZSTDOutBufferstructs.
-
Constructor Summary
Constructors Constructor Description ZSTDOutBuffer(java.nio.ByteBuffer container)Creates aZSTDOutBufferinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static ZSTDOutBuffercalloc()Returns a newZSTDOutBufferinstance allocated withmemCalloc.static ZSTDOutBuffer.Buffercalloc(int capacity)Returns a newZSTDOutBuffer.Bufferinstance allocated withmemCalloc.static ZSTDOutBuffer.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newZSTDOutBuffer.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static ZSTDOutBuffercalloc(org.lwjgl.system.MemoryStack stack)Returns a newZSTDOutBufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static ZSTDOutBuffercallocStack()Deprecated.static ZSTDOutBuffer.BuffercallocStack(int capacity)Deprecated.static ZSTDOutBuffer.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static ZSTDOutBuffercallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static ZSTDOutBuffercreate()Returns a newZSTDOutBufferinstance allocated withBufferUtils.static ZSTDOutBuffer.Buffercreate(int capacity)Returns a newZSTDOutBuffer.Bufferinstance allocated withBufferUtils.static ZSTDOutBuffercreate(long address)Returns a newZSTDOutBufferinstance for the specified memory address.static ZSTDOutBuffer.Buffercreate(long address, int capacity)Create aZSTDOutBuffer.Bufferinstance at the specified memory.static ZSTDOutBuffercreateSafe(long address)static ZSTDOutBuffer.BuffercreateSafe(long address, int capacity)java.nio.ByteBufferdst()start of output bufferZSTDOutBufferdst(java.nio.ByteBuffer value)Sets the address of the specifiedByteBufferto thedst()field.static ZSTDOutBuffermalloc()Returns a newZSTDOutBufferinstance allocated withmemAlloc.static ZSTDOutBuffer.Buffermalloc(int capacity)Returns a newZSTDOutBuffer.Bufferinstance allocated withmemAlloc.static ZSTDOutBuffer.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newZSTDOutBuffer.Bufferinstance allocated on the specifiedMemoryStack.static ZSTDOutBuffermalloc(org.lwjgl.system.MemoryStack stack)Returns a newZSTDOutBufferinstance allocated on the specifiedMemoryStack.static ZSTDOutBuffermallocStack()Deprecated.static ZSTDOutBuffer.BuffermallocStack(int capacity)Deprecated.static ZSTDOutBuffer.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static ZSTDOutBuffermallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static java.nio.ByteBufferndst(long struct)Unsafe version ofdst.static voidndst(long struct, java.nio.ByteBuffer value)Unsafe version ofdst.static longnpos(long struct)Unsafe version ofpos().static voidnpos(long struct, long value)Unsafe version ofpos.static longnsize(long struct)Unsafe version ofsize().static voidnsize(long struct, long value)Sets the specified value to thesizefield of the specifiedstruct.longpos()position where writing stopped.ZSTDOutBufferpos(long value)Sets the specified value to thepos()field.ZSTDOutBufferset(java.nio.ByteBuffer dst, long pos)Initializes this struct with the specified values.ZSTDOutBufferset(ZSTDOutBuffer src)Copies the specified struct data to this struct.longsize()size of output bufferintsizeof()static voidvalidate(long struct)Validates pointer members that should not beNULL.
-
-
-
Constructor Detail
-
ZSTDOutBuffer
public ZSTDOutBuffer(java.nio.ByteBuffer container)
Creates aZSTDOutBufferinstance 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 Detail
-
sizeof
public int sizeof()
- Specified by:
sizeofin classorg.lwjgl.system.Struct
-
dst
public java.nio.ByteBuffer dst()
start of output buffer
-
size
public long size()
size of output buffer
-
pos
public long pos()
position where writing stopped. Will be updated. Necessarily 0 ≤pos≤size
-
dst
public ZSTDOutBuffer dst(java.nio.ByteBuffer value)
Sets the address of the specifiedByteBufferto thedst()field.
-
pos
public ZSTDOutBuffer pos(long value)
Sets the specified value to thepos()field.
-
set
public ZSTDOutBuffer set(java.nio.ByteBuffer dst, long pos)
Initializes this struct with the specified values.
-
set
public ZSTDOutBuffer set(ZSTDOutBuffer src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static ZSTDOutBuffer malloc()
Returns a newZSTDOutBufferinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static ZSTDOutBuffer calloc()
Returns a newZSTDOutBufferinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static ZSTDOutBuffer create()
Returns a newZSTDOutBufferinstance allocated withBufferUtils.
-
create
public static ZSTDOutBuffer create(long address)
Returns a newZSTDOutBufferinstance for the specified memory address.
-
createSafe
@Nullable public static ZSTDOutBuffer createSafe(long address)
-
malloc
public static ZSTDOutBuffer.Buffer malloc(int capacity)
Returns a newZSTDOutBuffer.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static ZSTDOutBuffer.Buffer calloc(int capacity)
Returns a newZSTDOutBuffer.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static ZSTDOutBuffer.Buffer create(int capacity)
Returns a newZSTDOutBuffer.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static ZSTDOutBuffer.Buffer create(long address, int capacity)
Create aZSTDOutBuffer.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static ZSTDOutBuffer.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static ZSTDOutBuffer mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static ZSTDOutBuffer callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static ZSTDOutBuffer mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static ZSTDOutBuffer callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static ZSTDOutBuffer.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static ZSTDOutBuffer.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
mallocStack
@Deprecated public static ZSTDOutBuffer.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static ZSTDOutBuffer.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
malloc
public static ZSTDOutBuffer malloc(org.lwjgl.system.MemoryStack stack)
Returns a newZSTDOutBufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static ZSTDOutBuffer calloc(org.lwjgl.system.MemoryStack stack)
Returns a newZSTDOutBufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static ZSTDOutBuffer.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newZSTDOutBuffer.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static ZSTDOutBuffer.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newZSTDOutBuffer.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
ndst
public static java.nio.ByteBuffer ndst(long struct)
Unsafe version ofdst.
-
nsize
public static long nsize(long struct)
Unsafe version ofsize().
-
npos
public static long npos(long struct)
Unsafe version ofpos().
-
ndst
public static void ndst(long struct, java.nio.ByteBuffer value)Unsafe version ofdst.
-
nsize
public static void nsize(long struct, long value)Sets the specified value to thesizefield of the specifiedstruct.
-
npos
public static void npos(long struct, long value)Unsafe version ofpos.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL.- Parameters:
struct- the struct to validate
-
-