Package org.refcodes.net
Enum OauthToken
- java.lang.Object
-
- java.lang.Enum<OauthToken>
-
- org.refcodes.net.OauthToken
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<OauthToken>
,org.refcodes.mixin.PathAccessor
,HeaderFieldAccessor
public enum OauthToken extends java.lang.Enum<OauthToken> implements org.refcodes.mixin.PathAccessor, HeaderFieldAccessor
The Enum OauthToken.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.refcodes.net.HeaderFieldAccessor
HeaderFieldAccessor.HeaderFieldBuilder<B extends HeaderFieldAccessor.HeaderFieldBuilder<B>>, HeaderFieldAccessor.HeaderFieldMutator, HeaderFieldAccessor.HeaderFieldProperty
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ACCESS_TOKEN
The access token, see alsoTokenType
.EXPIRES_IN
REFRESH_TOKEN
SCOPE
OAuth scopes let you specify exactly how your application needs to access a user's resource.TOKEN_TYPE
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static OauthToken
fromHeaderField(HeaderField aHeaderField)
static OauthToken
fromPath(java.lang.String aPath)
HeaderField
getHeaderField()
Retrieves theHeaderField
from theHeaderField
property.java.lang.String
getPath()
static OauthToken
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static OauthToken[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
SCOPE
public static final OauthToken SCOPE
OAuth scopes let you specify exactly how your application needs to access a user's resource. Scope is specified on either the authorization or token endpoints using the parameter scope. Scope is expressed as a set of case-sensitive and space-delimited strings. The authorization server may override the scope request, in this case it must include scope in its response to inform a client of their actual scope. When a scope is not specified, the server may either fallback to a well-documented default, or fail the request.
-
EXPIRES_IN
public static final OauthToken EXPIRES_IN
-
REFRESH_TOKEN
public static final OauthToken REFRESH_TOKEN
-
TOKEN_TYPE
public static final OauthToken TOKEN_TYPE
-
ACCESS_TOKEN
public static final OauthToken ACCESS_TOKEN
The access token, see alsoTokenType
.
-
-
Method Detail
-
values
public static OauthToken[] 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 (OauthToken c : OauthToken.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static OauthToken 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
-
getHeaderField
public HeaderField getHeaderField()
Retrieves theHeaderField
from theHeaderField
property.- Specified by:
getHeaderField
in interfaceHeaderFieldAccessor
- Returns:
- The
HeaderField
stored by theHeaderField
property.
-
getPath
public java.lang.String getPath()
- Specified by:
getPath
in interfaceorg.refcodes.mixin.PathAccessor
-
fromPath
public static OauthToken fromPath(java.lang.String aPath)
-
fromHeaderField
public static OauthToken fromHeaderField(HeaderField aHeaderField)
-
-