public class MessageDigestAPI
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
byte[] |
digest() |
java.lang.String |
getAlgorithmName() |
static java.util.List<java.lang.String> |
getAlgorithmNames() |
static MessageDigestAPI |
getDigest(java.lang.String encodedState)
Restore a digest from string form of internal state.
|
static java.lang.String |
getEncodedState(MessageDigestAPI d)
Get the current internal state of the specified digest.
|
static MessageDigestAPI |
getInstance(java.lang.String algorithm)
Create a new bouncy castle message digest that supports state encoding.
|
void |
reset() |
void |
update(byte[] bytes) |
void |
update(byte[] bytes,
int offset,
int length) |
public static java.util.List<java.lang.String> getAlgorithmNames()
public static MessageDigestAPI getInstance(java.lang.String algorithm) throws java.security.NoSuchAlgorithmException
algorithm - case-insensitive digest algorithmjava.security.NoSuchAlgorithmException - if the specified algorithm is not supportedpublic static java.lang.String getEncodedState(MessageDigestAPI d)
d - an EncodableDigest instancepublic static MessageDigestAPI getDigest(java.lang.String encodedState) throws java.security.NoSuchAlgorithmException
encodedState - string form of internal statejava.security.NoSuchAlgorithmException - if the encoded state references an unsupported algorithmpublic java.lang.String getAlgorithmName()
public void update(byte[] bytes,
int offset,
int length)
public void update(byte[] bytes)
public byte[] digest()
public void reset()