Package io.github.astrapi69.checksum.api
Enum ChecksumAlgorithm
- java.lang.Object
-
- java.lang.Enum<ChecksumAlgorithm>
-
- io.github.astrapi69.checksum.api.ChecksumAlgorithm
-
- All Implemented Interfaces:
io.github.astrapi69.crypto.algorithm.Algorithm
,java.io.Serializable
,java.lang.Comparable<ChecksumAlgorithm>
public enum ChecksumAlgorithm extends java.lang.Enum<ChecksumAlgorithm> implements io.github.astrapi69.crypto.algorithm.Algorithm
-
-
Enum Constant Summary
Enum Constants Enum Constant Description MD2
The enum constant for MD2 algorithm.MD4
The enum constant for MD4 algorithm.MD5
The enum constant for MD5 algorithm.SHA_1
The enum constant for SHA-1 algorithm.SHA_256
The enum constant for SHA-256 algorithm.SHA_384
The enum constant for SHA-384 algorithm.SHA_512
The enum constant for SHA-512 algorithm.UNDEFINED
The enum constant for SHA-512 algorithm.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getAlgorithm()
static ChecksumAlgorithm
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ChecksumAlgorithm[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
MD2
public static final ChecksumAlgorithm MD2
The enum constant for MD2 algorithm.
-
MD4
public static final ChecksumAlgorithm MD4
The enum constant for MD4 algorithm.
-
MD5
public static final ChecksumAlgorithm MD5
The enum constant for MD5 algorithm.
-
SHA_1
public static final ChecksumAlgorithm SHA_1
The enum constant for SHA-1 algorithm.
-
SHA_256
public static final ChecksumAlgorithm SHA_256
The enum constant for SHA-256 algorithm.
-
SHA_384
public static final ChecksumAlgorithm SHA_384
The enum constant for SHA-384 algorithm.
-
SHA_512
public static final ChecksumAlgorithm SHA_512
The enum constant for SHA-512 algorithm.
-
UNDEFINED
public static final ChecksumAlgorithm UNDEFINED
The enum constant for SHA-512 algorithm.
-
-
Method Detail
-
values
public static ChecksumAlgorithm[] 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 (ChecksumAlgorithm c : ChecksumAlgorithm.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ChecksumAlgorithm valueOf(java.lang.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:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
getAlgorithm
public java.lang.String getAlgorithm()
- Specified by:
getAlgorithm
in interfaceio.github.astrapi69.crypto.algorithm.Algorithm
-
-