Package org.opensaml.security.credential
Enum UsageType
- java.lang.Object
-
- java.lang.Enum<UsageType>
-
- org.opensaml.security.credential.UsageType
-
- All Implemented Interfaces:
Serializable,Comparable<UsageType>
public enum UsageType extends Enum<UsageType>
Credential usage types.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ENCRYPTIONKey used for encryption processes.SIGNINGKey used for signature processes including TLS/SSL.UNSPECIFIEDDenotes that the purpose of the key was not specified.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetValue()Get the enum string value.static UsageTypevalueOf(String name)Returns the enum constant of this type with the specified name.static UsageType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ENCRYPTION
public static final UsageType ENCRYPTION
Key used for encryption processes.
-
SIGNING
public static final UsageType SIGNING
Key used for signature processes including TLS/SSL.
-
UNSPECIFIED
public static final UsageType UNSPECIFIED
Denotes that the purpose of the key was not specified.
-
-
Field Detail
-
value
private String value
Enum string value.
-
-
Constructor Detail
-
UsageType
private UsageType(@Nonnull String v)Constructor.- Parameters:
v- the enum string value
-
-
Method Detail
-
values
public static UsageType[] 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 (UsageType c : UsageType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static UsageType 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 nameNullPointerException- if the argument is null
-
getValue
@Nonnull public String getValue()
Get the enum string value.- Returns:
- the enum string value
-
-