Uses of Interface
com.google.common.hash.Hasher
Packages that use Hasher
-
Uses of Hasher in com.google.common.hash
Classes in com.google.common.hash that implement HasherModifier and TypeClassDescription(package private) class
AbstractHasher
that handles converting primitives to bytes using a scratchByteBuffer
and streams all bytes to a sink to compute the hash.(package private) class
An abstract implementation ofHasher
, which only requires subtypes to implementputByte(byte)
.private final class
In-memory stream-based implementation of Hasher.(package private) class
A convenience base class for implementors ofHasher
; handles accumulating data until an entire "chunk" (of implementation-dependent length) is ready to be hashed.private final class
Hasher that updates a checksum.(package private) static final class
private static final class
Hasher that updates aMac
(message authentication code).private static final class
Hasher that updates a message digest.private static final class
private static final class
private static final class
Fields in com.google.common.hash declared as HasherModifier and TypeFieldDescriptionprivate final Hasher
HashingInputStream.hasher
private final Hasher
HashingOutputStream.hasher
Methods in com.google.common.hash that return HasherModifier and TypeMethodDescriptionprivate Hasher
AbstractCompositeHashFunction.fromHashers
(Hasher[] hashers) AbstractCompositeHashFunction.newHasher()
AbstractCompositeHashFunction.newHasher
(int expectedInputSize) AbstractHashFunction.newHasher
(int expectedInputSize) AbstractNonStreamingHashFunction.newHasher()
AbstractNonStreamingHashFunction.newHasher
(int expectedInputSize) ChecksumHashFunction.newHasher()
Crc32cHashFunction.newHasher()
HashFunction.newHasher()
Begins a new hash code computation by returning an initialized, statefulHasher
instance that is ready to receive data.HashFunction.newHasher
(int expectedInputSize) Begins a new hash code computation asHashFunction.newHasher()
, but provides a hint of the expected size of the input (in bytes).MacHashFunction.newHasher()
MessageDigestHashFunction.newHasher()
Murmur3_128HashFunction.newHasher()
Murmur3_32HashFunction.newHasher()
SipHashFunction.newHasher()
final Hasher
AbstractHasher.putBoolean
(boolean b) Hasher.putBoolean
(boolean b) Equivalent toputByte(b ? (byte) 1 : (byte) 0)
.AbstractByteHasher.putByte
(byte b) AbstractNonStreamingHashFunction.BufferingHasher.putByte
(byte b) final Hasher
AbstractStreamingHasher.putByte
(byte b) Hasher.putByte
(byte b) Murmur3_32HashFunction.Murmur3_32Hasher.putByte
(byte b) AbstractByteHasher.putBytes
(byte[] bytes) AbstractByteHasher.putBytes
(byte[] bytes, int off, int len) AbstractByteHasher.putBytes
(ByteBuffer bytes) AbstractHasher.putBytes
(byte[] bytes) AbstractHasher.putBytes
(byte[] bytes, int off, int len) AbstractHasher.putBytes
(ByteBuffer b) AbstractNonStreamingHashFunction.BufferingHasher.putBytes
(byte[] bytes, int off, int len) AbstractNonStreamingHashFunction.BufferingHasher.putBytes
(ByteBuffer bytes) final Hasher
AbstractStreamingHasher.putBytes
(byte[] bytes, int off, int len) final Hasher
AbstractStreamingHasher.putBytes
(ByteBuffer readBuffer) Hasher.putBytes
(byte[] bytes) Hasher.putBytes
(byte[] bytes, int off, int len) Hasher.putBytes
(ByteBuffer bytes) Murmur3_32HashFunction.Murmur3_32Hasher.putBytes
(byte[] bytes, int off, int len) Murmur3_32HashFunction.Murmur3_32Hasher.putBytes
(ByteBuffer buffer) private Hasher
AbstractStreamingHasher.putBytesInternal
(ByteBuffer readBuffer) AbstractByteHasher.putChar
(char c) AbstractHasher.putChar
(char c) final Hasher
AbstractStreamingHasher.putChar
(char c) Hasher.putChar
(char c) Murmur3_32HashFunction.Murmur3_32Hasher.putChar
(char c) final Hasher
AbstractHasher.putDouble
(double d) Hasher.putDouble
(double d) Equivalent toputLong(Double.doubleToRawLongBits(d))
.final Hasher
AbstractHasher.putFloat
(float f) Hasher.putFloat
(float f) Equivalent toputInt(Float.floatToRawIntBits(f))
.AbstractByteHasher.putInt
(int i) AbstractHasher.putInt
(int i) final Hasher
AbstractStreamingHasher.putInt
(int i) Hasher.putInt
(int i) Murmur3_32HashFunction.Murmur3_32Hasher.putInt
(int i) AbstractByteHasher.putLong
(long l) AbstractHasher.putLong
(long l) final Hasher
AbstractStreamingHasher.putLong
(long l) Hasher.putLong
(long l) Murmur3_32HashFunction.Murmur3_32Hasher.putLong
(long l) <T> Hasher
<T> Hasher
A simple convenience forfunnel.funnel(object, this)
.AbstractByteHasher.putShort
(short s) AbstractHasher.putShort
(short s) final Hasher
AbstractStreamingHasher.putShort
(short s) Hasher.putShort
(short s) AbstractHasher.putString
(CharSequence charSequence, Charset charset) Hasher.putString
(CharSequence charSequence, Charset charset) Equivalent toputBytes(charSequence.toString().getBytes(charset))
.Murmur3_32HashFunction.Murmur3_32Hasher.putString
(CharSequence input, Charset charset) AbstractHasher.putUnencodedChars
(CharSequence charSequence) Hasher.putUnencodedChars
(CharSequence charSequence) Equivalent to processing eachchar
value in theCharSequence
, in order.private Hasher
AbstractByteHasher.update
(int bytes) Updates the sink with the given number of bytes from the buffer.Methods in com.google.common.hash with parameters of type HasherModifier and TypeMethodDescriptionprivate Hasher
AbstractCompositeHashFunction.fromHashers
(Hasher[] hashers) (package private) abstract HashCode
Constructs aHashCode
from theHasher
objects of the functions.(package private) HashCode