eu.scape_project.core.api
Enum DigestValue.DigestAlgorithm

java.lang.Object
  extended by java.lang.Enum<DigestValue.DigestAlgorithm>
      extended by eu.scape_project.core.api.DigestValue.DigestAlgorithm
All Implemented Interfaces:
Serializable, Comparable<DigestValue.DigestAlgorithm>
Enclosing interface:
DigestValue

public static enum DigestValue.DigestAlgorithm
extends Enum<DigestValue.DigestAlgorithm>

Enum to identify the java supported digest algorithms. The name field is used to identify the algorithm for java.security.MessageDigest. The list isn't supposed to be authoritative but was grabbed by the code in the DigestUtilities class that lists the providers and algorithms.

Author:
Carl Wilson carlwilson-bl@SourceForge carlwilson-bl@github

Enum Constant Summary
MD2
          MD5 algorithm identifier
MD5
          MD5 algorithm identifier
SHA
          SHA algorithm identifier
SHA1
          SHA1 algorithm identifier
SHA256
          SHA256 algorithm identifier
SHA384
          SHA384 algorithm identifier
SHA512
          SHA512 algorithm identifier
 
Field Summary
static String ALGID_URI_PREFIX
          SCAPE algorithm id URI scheme prefix
 
Method Summary
 URI getId()
           
 String getJavaName()
           
static DigestValue.DigestAlgorithm valueOf(String name)
          Returns the enum constant of this type with the specified name.
static DigestValue.DigestAlgorithm[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

MD2

public static final DigestValue.DigestAlgorithm MD2
MD5 algorithm identifier


MD5

public static final DigestValue.DigestAlgorithm MD5
MD5 algorithm identifier


SHA

public static final DigestValue.DigestAlgorithm SHA
SHA algorithm identifier


SHA1

public static final DigestValue.DigestAlgorithm SHA1
SHA1 algorithm identifier


SHA256

public static final DigestValue.DigestAlgorithm SHA256
SHA256 algorithm identifier


SHA384

public static final DigestValue.DigestAlgorithm SHA384
SHA384 algorithm identifier


SHA512

public static final DigestValue.DigestAlgorithm SHA512
SHA512 algorithm identifier

Field Detail

ALGID_URI_PREFIX

public static final String ALGID_URI_PREFIX
SCAPE algorithm id URI scheme prefix

See Also:
Constant Field Values
Method Detail

values

public static DigestValue.DigestAlgorithm[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (DigestValue.DigestAlgorithm c : DigestValue.DigestAlgorithm.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static DigestValue.DigestAlgorithm valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getJavaName

public final String getJavaName()
Returns:
the java name for the enum instance

getId

public final URI getId()
Returns:
the scape digest algorithm id


Copyright © 2013. All Rights Reserved.