|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.rim.device.api.crypto.DigestFactory
public abstract class DigestFactory
Creates a digest.
For more information on the cryptographic algorithms supported by this factory, see Crypto Algorithms.
DigestInputStream,
DigestOutputStream| Constructor Summary | ||
|---|---|---|
|
protected |
DigestFactory()
Creates a DigestFactory object. |
| Method Summary | ||
|---|---|---|
|
protected abstract Digest |
create(String algorithm)
Called to create the Digest. |
|
static Enumeration |
getAlgorithms()
Returns an Enumeration of String representing all of the
registered algorithms with this factory. |
|
protected abstract String[] |
getFactoryAlgorithms()
Called to determine what algorithms are supported. |
|
static Digest |
getInstance(String algorithm)
Constructs and returns a new Digest object. |
|
static void |
register(DigestFactory factory)
Registers the given Digest object. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected DigestFactory()
DigestFactory object.
This is the default constructor and is not used.
| Method Detail |
|---|
public static Digest getInstance(String algorithm)
throws NoSuchAlgorithmException
Digest object.
algorithm - The name of the digest to construct, eg "SHA1", "MD5",
etc.
NoSuchAlgorithmException - Thrown if the digest cannot be constructed.public static void register(DigestFactory factory)
Digest object.
If a previous call registered a Digest with the same algorithm name, then the new one will be ignored.
factory - The digest factory to be registered.public static Enumeration getAlgorithms()
String representing all of the
registered algorithms with this factory.
protected abstract String[] getFactoryAlgorithms()
protected abstract Digest create(String algorithm)
throws NoSuchAlgorithmException
algorithm - The algorithm used to create the digest.
NoSuchAlgorithmException - Thrown if the specified algorithm was
not valid.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2010 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark of Sun Microsystems, Inc.