public class HashBuilder
extends java.lang.Object
| Constructor and Description |
|---|
HashBuilder(java.lang.String txt)
Defines the hash builder helper with the given text content.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getHashCode(HashAlgorithm algorithm)
Calculates the hash code with the given hash algorithm.
|
java.lang.String |
getMd5()
Gets the md5.
|
protected static java.security.MessageDigest |
getMessageDigest(java.lang.String algorithm)
Gets the message digest.
|
java.lang.String |
getSha1()
Gets the sha1.
|
java.lang.String |
getSha256()
Gets the sha256.
|
java.lang.String |
getSha512()
Gets the sha512.
|
public HashBuilder(java.lang.String txt)
txt - the text hash value will be generated forpublic java.lang.String getMd5()
public java.lang.String getSha1()
public java.lang.String getSha256()
public java.lang.String getSha512()
public java.lang.String getHashCode(HashAlgorithm algorithm)
algorithm - the algorithmprotected static java.security.MessageDigest getMessageDigest(java.lang.String algorithm)
algorithm - the algorithm