Index

A B C D E H I N O S T U V 
All Classes and Interfaces|All Packages

A

algorithm() - Method in class com.github.benjaminmoran.superfluous.hash.Digest
Returns the hash function which created this digest.
algorithm() - Method in interface com.github.benjaminmoran.superfluous.hash.Hasher
Returns a hash function which generates hashers of the same type as this one.

B

bytes() - Method in class com.github.benjaminmoran.superfluous.hash.Digest
Returns the bytes of this digest.

C

com.github.benjaminmoran.superfluous.hash - package com.github.benjaminmoran.superfluous.hash
All types are non-null except where otherwise stated.

D

digest() - Method in interface com.github.benjaminmoran.superfluous.hash.Hasher
Returns the digest of the input received.
Digest - Class in com.github.benjaminmoran.superfluous.hash
An immutable wrapper for a byte array, tagged with the hash function which created it.
digestLength() - Method in interface com.github.benjaminmoran.superfluous.hash.HashFunction
Returns the length in bytes of the digests output by this hash function.

E

equals(Object) - Method in class com.github.benjaminmoran.superfluous.hash.Digest
Compares this object to the specified object.

H

hash(byte[]) - Method in interface com.github.benjaminmoran.superfluous.hash.HashFunction
Applies this hash function to the given message and returns the digest computed.
hash(byte[], int, int) - Method in interface com.github.benjaminmoran.superfluous.hash.HashFunction
Applies this hash function to a sub-array of the input and returns the digest computed.
hashCode() - Method in class com.github.benjaminmoran.superfluous.hash.Digest
Returns the four most significant bytes of this digest as a big-endian int.
Hasher - Interface in com.github.benjaminmoran.superfluous.hash
The mutable intermediate state of a hash algorithm.
HashFunction - Interface in com.github.benjaminmoran.superfluous.hash
A deterministic mapping from messages to digests.
HashFunctions - Class in com.github.benjaminmoran.superfluous.hash
Standard hash functions.
hex() - Method in class com.github.benjaminmoran.superfluous.hash.Digest
Returns a hexadecimal representation of this digest.

I

init() - Method in interface com.github.benjaminmoran.superfluous.hash.HashFunction
Allows incremental hashing by creating a stateful Hasher which can be updated with parts of the message at a time.

N

name() - Method in interface com.github.benjaminmoran.superfluous.hash.HashFunction
Returns a string identifying this hash function.

O

of(HashFunction, byte[]) - Static method in class com.github.benjaminmoran.superfluous.hash.Digest
Tags a byte array with the hash function which created it.
of(String, int, Supplier<Hasher>) - Static method in interface com.github.benjaminmoran.superfluous.hash.HashFunction
Creates a HashFunction instance from a Hasher constructor.

S

sha256() - Static method in class com.github.benjaminmoran.superfluous.hash.HashFunctions
Returns the SHA-256 hash function.

T

toString() - Method in class com.github.benjaminmoran.superfluous.hash.Digest
Returns a hexadecimal representation of this digest.

U

update(byte[]) - Method in interface com.github.benjaminmoran.superfluous.hash.Hasher
Appends input to the message to be hashed.
update(byte[], int, int) - Method in interface com.github.benjaminmoran.superfluous.hash.Hasher
Appends a sub-array of input to the message to be hashed.

V

verifyMessage(byte[]) - Method in class com.github.benjaminmoran.superfluous.hash.Digest
Tests whether a message matches this hash digest.
A B C D E H I N O S T U V 
All Classes and Interfaces|All Packages