public enum SignedRequestVersion extends Enum<SignedRequestVersion> implements Version
List of supported signed request versions with associated version rules.
Version.Error
Enum Constant and Description |
---|
ONE |
Modifier and Type | Method and Description |
---|---|
static SignedRequestVersion |
getLatestVersion()
Get the latest signed request version.
|
int |
getMinimumKeySizeInBits()
Get the minimum public key size in bits.
|
Set<Algorithm> |
getSupportedAlgorithms()
Get a set of supported algorithms.
|
Set<KeyIdType> |
getSupportedKeyIdTypes()
Get a set of supported keyId types.
|
String |
getVersionName()
Get the name of this version - usually the version number as a String.
|
int |
getVersionNumber()
Get the version number.
|
Optional<Version.Error> |
validateAlgorithm(Algorithm algorithm) |
Optional<Version.Error> |
validateKeyId(String keyId) |
Optional<Version.Error> |
validateKeySize(RSAPublicKey publicKey) |
static SignedRequestVersion |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SignedRequestVersion[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SignedRequestVersion ONE
public static SignedRequestVersion[] values()
for (SignedRequestVersion c : SignedRequestVersion.values()) System.out.println(c);
public static SignedRequestVersion valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic Set<Algorithm> getSupportedAlgorithms()
Version
Get a set of supported algorithms.
getSupportedAlgorithms
in interface Version
public Set<KeyIdType> getSupportedKeyIdTypes()
Version
Get a set of supported keyId types.
getSupportedKeyIdTypes
in interface Version
public int getVersionNumber()
Version
Get the version number.
getVersionNumber
in interface Version
public String getVersionName()
Version
Get the name of this version - usually the version number as a String.
getVersionName
in interface Version
public int getMinimumKeySizeInBits()
Version
Get the minimum public key size in bits.
getMinimumKeySizeInBits
in interface Version
public Optional<Version.Error> validateKeyId(@Nonnull String keyId)
validateKeyId
in interface Version
public Optional<Version.Error> validateAlgorithm(@Nonnull Algorithm algorithm)
validateAlgorithm
in interface Version
public Optional<Version.Error> validateKeySize(@Nonnull RSAPublicKey publicKey)
validateKeySize
in interface Version
public static SignedRequestVersion getLatestVersion()
Get the latest signed request version.
Copyright © 2016–2024. All rights reserved.