public final class OAuth1ClientSupport extends Object
The support for OAuth is divided into two parts:
This class contains static method that allows to build both OAuth1 features (authorization flow and client feature).
OAuth1AuthorizationFlow
interface. The result of the process is
an AccessToken
.client
are
enhanced by an Authorization
http header that contains OAuth1 authorization information
based on the AccessToken
received from Authorization flow. This support is provided by
oauth 1 filter feature
that is registered into client configuration.
Modifier and Type | Field and Description |
---|---|
static String |
OAUTH_PROPERTY_ACCESS_TOKEN
Key of the property that can be attached to the
client request using
ClientRequestContext.setProperty(String, Object) and that
defines access token that should be used when generating OAuth Authorization
http header. |
static String |
OAUTH_PROPERTY_CONSUMER_CREDENTIALS
Key of the property that can be attached to the
client request using
ClientRequestContext.setProperty(String, Object) and that
defines consumer credentials that should be used when generating OAuth Authorization
http header. |
static String |
OAUTH_PROPERTY_OAUTH_PARAMETERS
Key of the property that can be attached to the
client request using
ClientRequestContext.setProperty(String, Object) and that
defines OAuth1Parameters
that should be used when generating OAuth Authorization
http header. |
static String |
OAUTH_PROPERTY_OAUTH_SECRETS
Key of the property that can be attached to the
client request using
ClientRequestContext.setProperty(String, Object) and that
defines OAuth1Secrets
that should be used when generating OAuth Authorization
http header. |
Modifier and Type | Method and Description |
---|---|
static OAuth1Builder |
builder(ConsumerCredentials consumerCredentials)
Get a new builder of OAuth1 client support.
|
public static final String OAUTH_PROPERTY_CONSUMER_CREDENTIALS
client request
using
ClientRequestContext.setProperty(String, Object)
and that
defines consumer credentials
that should be used when generating OAuth Authorization
http header. The property will override the setting of the internal
filter
for the current request only.
The value of the property must be ConsumerCredentials
instance.
public static final String OAUTH_PROPERTY_ACCESS_TOKEN
client request
using
ClientRequestContext.setProperty(String, Object)
and that
defines access token
that should be used when generating OAuth Authorization
http header. The property will override the setting of the internal
filter
for the current request only.
The value of the property must be AccessToken
instance.
public static final String OAUTH_PROPERTY_OAUTH_PARAMETERS
client request
using
ClientRequestContext.setProperty(String, Object)
and that
defines OAuth1Parameters
that should be used when generating OAuth Authorization
http header. The property will override the setting of the internal
filter
for the current request only.
The value of the property must be OAuth1Parameters
instance.
This property is for advanced usage and should not be used if not needed as it can make the filter configuration inconsistent for the request and can produce unwanted results.
This property should be used only for configuring an instance of OAuth feature
, not the
Authorization flow
.
public static final String OAUTH_PROPERTY_OAUTH_SECRETS
client request
using
ClientRequestContext.setProperty(String, Object)
and that
defines OAuth1Secrets
that should be used when generating OAuth Authorization
http header. The property will override the setting of the internal
filter
for the current request only.
The value of the property must be OAuth1Secrets
instance.
This property is for advanced usage and should not be used if not needed as it can make the filter configuration inconsistent for the request and can produce unwanted results.
This property should be used only for configuring an instance of OAuth feature
, not the
Authorization flow
.
public static OAuth1Builder builder(ConsumerCredentials consumerCredentials)
consumerCredentials
- Consumer credentials issued by the service provider for the application that
wants to access data.Copyright © 2007-2015, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.