Class XXHash
- java.lang.Object
-
- software.amazon.awssdk.crt.CrtResource
-
- software.amazon.awssdk.crt.checksums.XXHash
-
- All Implemented Interfaces:
AutoCloseable
public class XXHash extends CrtResource
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class software.amazon.awssdk.crt.CrtResource
CrtResource.ResourceInstance
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static byte[]computeXXHash3_128(byte[] input)Oneshot compute XXHash3_128.static byte[]computeXXHash3_128(byte[] input, long seed)Oneshot compute XXHash3_128.static byte[]computeXXHash3_64(byte[] input)Oneshot compute XXHash3_64.static byte[]computeXXHash3_64(byte[] input, long seed)Oneshot compute XXHash3_64.static byte[]computeXXHash64(byte[] input)Oneshot compute XXHash64.static byte[]computeXXHash64(byte[] input, long seed)Oneshot compute XXHash64.byte[]digest()Return digest for the current state of hash.static XXHashnewXXHash3_128()Create new streaming XXHash3_128.static XXHashnewXXHash3_128(long seed)Create new streaming XXHash3_128.static XXHashnewXXHash3_64()Create new streaming XXHash3_64.static XXHashnewXXHash3_64(long seed)Create new streaming XXHash3_64.static XXHashnewXXHash64()Create new streaming XXHash64.static XXHashnewXXHash64(long seed)Create new streaming XXHash64.voidupdate(byte[] input)Update xxhash state from input-
Methods inherited from class software.amazon.awssdk.crt.CrtResource
addRef, addRef, addReferenceTo, close, close, collectNativeResource, collectNativeResources, decRef, decRef, decRef, getNativeHandle, getResourceLogDescription, isNull, logNativeResources, logNativeResources, removeReferenceTo, setDescription, waitForNoResources
-
-
-
-
Method Detail
-
newXXHash64
public static XXHash newXXHash64(long seed)
Create new streaming XXHash64.- Parameters:
seed- seed to use for the hash- Returns:
- new XXHash instance
-
newXXHash64
public static XXHash newXXHash64()
Create new streaming XXHash64.- Returns:
- new XXHash instance
-
newXXHash3_64
public static XXHash newXXHash3_64(long seed)
Create new streaming XXHash3_64.- Parameters:
seed- seed to use for the hash- Returns:
- new XXHash instance
-
newXXHash3_64
public static XXHash newXXHash3_64()
Create new streaming XXHash3_64.- Returns:
- new XXHash instance
-
newXXHash3_128
public static XXHash newXXHash3_128(long seed)
Create new streaming XXHash3_128.- Parameters:
seed- seed to use for the hash- Returns:
- new XXHash instance
-
newXXHash3_128
public static XXHash newXXHash3_128()
Create new streaming XXHash3_128.- Returns:
- new XXHash instance
-
update
public void update(byte[] input)
Update xxhash state from input- Parameters:
input- input to update with
-
digest
public byte[] digest()
Return digest for the current state of hash.- Returns:
- hash as bytes in big endian
-
computeXXHash64
public static byte[] computeXXHash64(byte[] input, long seed)Oneshot compute XXHash64.- Parameters:
input- input input to hashseed- seed- Returns:
- xxhash64 hash
-
computeXXHash64
public static byte[] computeXXHash64(byte[] input)
Oneshot compute XXHash64.- Parameters:
input- input input to hash- Returns:
- xxhash64 hash
-
computeXXHash3_64
public static byte[] computeXXHash3_64(byte[] input, long seed)Oneshot compute XXHash3_64.- Parameters:
input- input input to hashseed- seed- Returns:
- xxhash64 hash
-
computeXXHash3_64
public static byte[] computeXXHash3_64(byte[] input)
Oneshot compute XXHash3_64.- Parameters:
input- input input to hash- Returns:
- xxhash64 hash
-
computeXXHash3_128
public static byte[] computeXXHash3_128(byte[] input, long seed)Oneshot compute XXHash3_128.- Parameters:
input- input input to hashseed- seed- Returns:
- xxhash64 hash
-
computeXXHash3_128
public static byte[] computeXXHash3_128(byte[] input)
Oneshot compute XXHash3_128.- Parameters:
input- input input to hash- Returns:
- xxhash64 hash
-
-