Package xades4j.providers.impl
Class DefaultMessageDigestProvider
java.lang.Object
xades4j.providers.impl.DefaultMessageDigestProvider
- All Implemented Interfaces:
MessageDigestEngineProvider
The default implementation of
MessageDigestEngineProvider
. It supports
Apache Santuario available algorithms- Author:
- Luís
-
Constructor Summary
ConstructorsConstructorDescriptionInitializes a new instance that will get MessageDigests without specifying a JCE provider.DefaultMessageDigestProvider
(String messageDigestProvider) Initializes a new instance that will use the specified JCE provider to get MessageDigest instances. -
Method Summary
Modifier and TypeMethodDescriptionGets aMessageDigest
engine for the algorithm identified by the given URI.
-
Constructor Details
-
DefaultMessageDigestProvider
Initializes a new instance that will use the specified JCE provider to get MessageDigest instances.- Parameters:
messageDigestProvider
- the JCE provider for MessageDigest- Throws:
NoSuchProviderException
- if the JCE provider is not installed
-
DefaultMessageDigestProvider
public DefaultMessageDigestProvider()Initializes a new instance that will get MessageDigests without specifying a JCE provider.
-
-
Method Details
-
getEngine
Description copied from interface:MessageDigestEngineProvider
Gets aMessageDigest
engine for the algorithm identified by the given URI. The URIs defined in the XML-DSIG specification are used.- Specified by:
getEngine
in interfaceMessageDigestEngineProvider
- Parameters:
digestAlgorithmURI
- the URI of the digest algorithm- Returns:
- the message digest engine
- Throws:
UnsupportedAlgorithmException
- if the current provider doesn't support the specified algorithm URI or there is no provider in the platform for the corresponding algorithm name
-