Serializable
, Comparable<TokenType>
public enum TokenType extends Enum<TokenType>
Enum Constant | Description |
---|---|
BEARER |
Any party in possession of a bearer token (a "bearer") can use it to get
access to the associated resources (without demonstrating possession of a
cryptographic key).
|
MAC |
Use MAC Tokens in HTTP requests to access OAuth 2.0 protected resources.
|
Modifier and Type | Method | Description |
---|---|---|
static TokenType |
fromName(String aName) |
Returns that
TokenType represented by the given name. |
String |
getName() |
Gets the name.
|
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 BEARER
TokenType
in an HTTP-Header HeaderField.TOKEN_TYPE
in
case you want to use the BEARER
token type. See also
"https://tools.ietf.org/html/rfc6750"public static final TokenType MAC
TokenType
in an HTTP-Header HeaderField.TOKEN_TYPE
in case you want to use the MAC
token type.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 String getName()
Copyright © 2021. All rights reserved.