Package org.lwjgl.util.xxhash
Class XXH32State
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.util.xxhash.XXH32State
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class XXH32State extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceThe opaque state struct for the XXH32 streaming API.Layout
struct XXH32_state_t { XXH32_hash_ttotal_len_32(); XXH32_hash_tlarge_len(); XXH32_hash_tv()[4]; XXH32_hash_tmem32()[4]; XXH32_hash_tmemsize(); XXH32_hash_treserved(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXXH32State.BufferAn array ofXXH32Statestructs.
-
Constructor Summary
Constructors Constructor Description XXH32State(java.nio.ByteBuffer container)Creates aXXH32Stateinstance 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 XXH32Statecalloc()Returns a newXXH32Stateinstance allocated withmemCalloc.static XXH32State.Buffercalloc(int capacity)Returns a newXXH32State.Bufferinstance allocated withmemCalloc.static XXH32State.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXXH32State.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XXH32Statecalloc(org.lwjgl.system.MemoryStack stack)Returns a newXXH32Stateinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XXH32StatecallocStack()Deprecated.static XXH32State.BuffercallocStack(int capacity)Deprecated.static XXH32State.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static XXH32StatecallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static XXH32Statecreate()Returns a newXXH32Stateinstance allocated withBufferUtils.static XXH32State.Buffercreate(int capacity)Returns a newXXH32State.Bufferinstance allocated withBufferUtils.static XXH32Statecreate(long address)Returns a newXXH32Stateinstance for the specified memory address.static XXH32State.Buffercreate(long address, int capacity)Create aXXH32State.Bufferinstance at the specified memory.static XXH32StatecreateSafe(long address)static XXH32State.BuffercreateSafe(long address, int capacity)intlarge_len()whether the hash is ≥ 16 (handlestotal_len_32overflow)static XXH32Statemalloc()Returns a newXXH32Stateinstance allocated withmemAlloc.static XXH32State.Buffermalloc(int capacity)Returns a newXXH32State.Bufferinstance allocated withmemAlloc.static XXH32State.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXXH32State.Bufferinstance allocated on the specifiedMemoryStack.static XXH32Statemalloc(org.lwjgl.system.MemoryStack stack)Returns a newXXH32Stateinstance allocated on the specifiedMemoryStack.static XXH32StatemallocStack()Deprecated.static XXH32State.BuffermallocStack(int capacity)Deprecated.static XXH32State.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static XXH32StatemallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.java.nio.IntBuffermem32()internal buffer for partial reads.intmem32(int index)internal buffer for partial reads.intmemsize()amount of data inmem32static intnlarge_len(long struct)Unsafe version oflarge_len().static java.nio.IntBuffernmem32(long struct)Unsafe version ofmem32().static intnmem32(long struct, int index)Unsafe version ofmem32.static intnmemsize(long struct)Unsafe version ofmemsize().static intnreserved(long struct)Unsafe version ofreserved().static intntotal_len_32(long struct)Unsafe version oftotal_len_32().static java.nio.IntBuffernv(long struct)Unsafe version ofv().static intnv(long struct, int index)Unsafe version ofv.intreserved()reserved field.intsizeof()inttotal_len_32()total length hashed, modulo2^32java.nio.IntBufferv()accumulator lanesintv(int index)accumulator lanes
-
-
-
Constructor Detail
-
XXH32State
public XXH32State(java.nio.ByteBuffer container)
Creates aXXH32Stateinstance 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
-
total_len_32
public int total_len_32()
total length hashed, modulo2^32
-
large_len
public int large_len()
whether the hash is ≥ 16 (handlestotal_len_32overflow)
-
v
public java.nio.IntBuffer v() public int v(int index)
accumulator lanes
-
mem32
public java.nio.IntBuffer mem32() public int mem32(int index)
internal buffer for partial reads. Treated asunsigned char[16].
-
memsize
public int memsize()
amount of data inmem32
-
reserved
public int reserved()
reserved field. Do not read or write to it, it may be removed.
-
malloc
public static XXH32State malloc()
Returns a newXXH32Stateinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static XXH32State calloc()
Returns a newXXH32Stateinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static XXH32State create()
Returns a newXXH32Stateinstance allocated withBufferUtils.
-
create
public static XXH32State create(long address)
Returns a newXXH32Stateinstance for the specified memory address.
-
createSafe
@Nullable public static XXH32State createSafe(long address)
-
malloc
public static XXH32State.Buffer malloc(int capacity)
Returns a newXXH32State.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static XXH32State.Buffer calloc(int capacity)
Returns a newXXH32State.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static XXH32State.Buffer create(int capacity)
Returns a newXXH32State.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static XXH32State.Buffer create(long address, int capacity)
Create aXXH32State.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static XXH32State.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static XXH32State mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static XXH32State callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static XXH32State mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static XXH32State callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static XXH32State.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static XXH32State.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
mallocStack
@Deprecated public static XXH32State.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 XXH32State.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
malloc
public static XXH32State malloc(org.lwjgl.system.MemoryStack stack)
Returns a newXXH32Stateinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static XXH32State calloc(org.lwjgl.system.MemoryStack stack)
Returns a newXXH32Stateinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static XXH32State.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXXH32State.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static XXH32State.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXXH32State.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
ntotal_len_32
public static int ntotal_len_32(long struct)
Unsafe version oftotal_len_32().
-
nlarge_len
public static int nlarge_len(long struct)
Unsafe version oflarge_len().
-
nv
public static java.nio.IntBuffer nv(long struct)
Unsafe version ofv().
-
nv
public static int nv(long struct, int index)Unsafe version ofv.
-
nmem32
public static java.nio.IntBuffer nmem32(long struct)
Unsafe version ofmem32().
-
nmem32
public static int nmem32(long struct, int index)Unsafe version ofmem32.
-
nmemsize
public static int nmemsize(long struct)
Unsafe version ofmemsize().
-
nreserved
public static int nreserved(long struct)
Unsafe version ofreserved().
-
-