public class AlgorithmId
extends java.lang.Object
implements java.io.Serializable
get(String)
The OID is handled in it's String format in this class. example 1.2.840.113549.1.1.11 for "SHA256withRSA"Constructor and Description |
---|
AlgorithmId()
Deprecated.
use one of the other constructors.
|
AlgorithmId(java.lang.String oid)
Constructs a parameterless algorithm ID.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(AlgorithmId other)
Returns true iff the argument indicates the same algorithm with the same parameters.
|
boolean |
equals(java.lang.Object other)
Compares this AlgorithmID to another.
|
boolean |
equals(java.lang.String id)
Compares two algorithm IDs for equality.
|
static AlgorithmId |
get(java.lang.String algname)
Returns one of the algorithm IDs most commonly associated with this algorithm name.
|
static AlgorithmId |
getAlgorithmId(java.lang.String algname)
Deprecated.
use the short get form of this method.
|
static java.lang.String |
getDigAlgFromSigAlg(java.lang.String signatureAlgorithm)
Extracts the digest algorithm name from a signature algorithm name.
|
static java.lang.String |
getEncAlgFromSigAlg(java.lang.String signatureAlgorithm)
Extracts the encryption algorithm name from a signature algorithm name.
|
java.lang.String |
getOID()
Returns the ISO OID for this algorithm.
|
int |
hashCode()
Returns a hashcode for this AlgorithmId.
|
static java.lang.String |
makeSigAlg(java.lang.String digAlg,
java.lang.String encAlg)
Creates a signature algorithm name from a digest algorithm name and a encryption algorithm name.
|
@Deprecated public AlgorithmId()
public AlgorithmId(java.lang.String oid)
oid
- the identifier for the algorithmpublic final java.lang.String getOID()
getName
call when you do not need to
ensure cross-system portability of algorithm names, or need a user friendly name.public boolean equals(AlgorithmId other)
other
- public boolean equals(@Nullable java.lang.Object other)
equals
in class java.lang.Object
other
- preferably an AlgorithmId, else an ObjectIdentifierpublic final boolean equals(java.lang.String id)
public int hashCode()
hashCode
in class java.lang.Object
@Deprecated public static AlgorithmId getAlgorithmId(java.lang.String algname) throws NoSuchAlgorithmException
algname
- the name being usedNoSuchAlgorithmException
- on error.public static AlgorithmId get(java.lang.String algname) throws NoSuchAlgorithmException
algname
- the name being usedNoSuchAlgorithmException
- on error.public static java.lang.String makeSigAlg(java.lang.String digAlg, java.lang.String encAlg)
public static java.lang.String getEncAlgFromSigAlg(java.lang.String signatureAlgorithm)
public static java.lang.String getDigAlgFromSigAlg(java.lang.String signatureAlgorithm)