public final class HashAlgorithmRegistry extends Object
Please, make sure you register your algorithm with {
registerHashAlgorithm(String, HashAlgorithm) before referring to it
by name
| Modifier and Type | Method and Description |
|---|---|
static HashAlgorithm |
lookupHashAlgorithm(String name)
Tries to find selected hash algorithm using name provided.
|
static void |
registerHashAlgorithm(String name,
HashAlgorithm alg)
Registers provided
HashAlgorithm instance with the given name. |
public static void registerHashAlgorithm(String name, HashAlgorithm alg)
HashAlgorithm instance with the given name. Name
is not case sensitive. Any registered algorithm with the same name will be
substitutedname - name of the algorithmalg - algorithm instance to registerpublic static HashAlgorithm lookupHashAlgorithm(String name)
Note, that lookup is being performed using name's lower-case value
name - the algorithm name to be used for lookupHashAlgorithm instance or null if there's no
algorithm with the specified nameCopyright © 2019. All rights reserved.