public enum TokenType extends Enum<TokenType>
Enum Constant and Description |
---|
ACCESS_TOKEN
Token type URI for an OAuth 2.0 access token;
"urn:ietf:params:oauth:token-type:access_token" . |
ID_TOKEN
Token type URI for an ID Token;
"urn:ietf:params:oauth:token-type:id_token" . |
JWT
JSON Web Token (JWT) Token Type;
"urn:ietf:params:oauth:token-type:jwt" . |
REFRESH_TOKEN
Token type URI for an OAuth 2.0 refresh token;
"urn:ietf:params:oauth:token-type:refresh_token" . |
SAML1
Token type URI for a base64url-encoded SAML 1.1 assertion;
"urn:ietf:params:oauth:token-type:saml1" . |
SAML2
Token type URI for a base64url-encoded SAML 2.0 assertion;
"urn:ietf:params:oauth:token-type:saml2" . |
Modifier and Type | Method and Description |
---|---|
static TokenType |
getByValue(short value)
Find an instance of this enum by a value.
|
short |
getValue()
Get the integer representation of this enum instance.
|
static TokenType |
parse(String tokenType)
Convert
String to TokenType . |
static TokenType[] |
toArray(int bits) |
static int |
toBits(EnumSet<TokenType> set) |
static EnumSet<TokenType> |
toSet(int bits) |
static EnumSet<TokenType> |
toSet(TokenType[] array) |
String |
toString() |
static TokenType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TokenType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final TokenType JWT
"urn:ietf:params:oauth:token-type:jwt"
.public static final TokenType ACCESS_TOKEN
"urn:ietf:params:oauth:token-type:access_token"
.public static final TokenType REFRESH_TOKEN
"urn:ietf:params:oauth:token-type:refresh_token"
.public static final TokenType ID_TOKEN
"urn:ietf:params:oauth:token-type:id_token"
.public static final TokenType SAML1
"urn:ietf:params:oauth:token-type:saml1"
.public static final TokenType SAML2
"urn:ietf:params:oauth:token-type:saml2"
.public static TokenType[] values()
for (TokenType c : TokenType.values()) System.out.println(c);
public static TokenType 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 short getValue()
public static TokenType getByValue(short value)
value
- The integer representation of the instance to find.null
if not found.public static TokenType parse(String tokenType)
String
to TokenType
.tokenType
- A token type. For example,
"urn:ietf:params:oauth:token-type:access_token"
.TokenType
instance, or null
.public static TokenType[] toArray(int bits)
Copyright © 2023. All rights reserved.