com.google.api.client.auth.oauth
Class AbstractOAuthGetToken
java.lang.Object
java.util.AbstractMap<String,Object>
com.google.api.client.util.GenericData
com.google.api.client.http.GenericUrl
com.google.api.client.auth.oauth.AbstractOAuthGetToken
- All Implemented Interfaces:
- Cloneable, Map<String,Object>
- Direct Known Subclasses:
- OAuthGetAccessToken, OAuthGetTemporaryToken
public abstract class AbstractOAuthGetToken
- extends GenericUrl
Generic OAuth 1.0a URL to request a temporary or long-lived token from an authorization server.
- Since:
- 1.0
- Author:
- Yaniv Inbar
| Nested classes/interfaces inherited from interface java.util.Map |
Map.Entry<K,V> |
| Methods inherited from class com.google.api.client.http.GenericUrl |
appendRawPath, build, clone, equals, getAll, getFirst, getRawPath, hashCode, setRawPath, toPathParts, toString |
transport
public HttpTransport transport
- HTTP transport required for executing request in
execute().
- Since:
- 1.3
consumerKey
public String consumerKey
- Required identifier portion of the client credentials (equivalent to a username).
signer
public OAuthSigner signer
- Required OAuth signature algorithm.
usePost
protected boolean usePost
true for POST request or the default false for GET request.
AbstractOAuthGetToken
protected AbstractOAuthGetToken(String authorizationServerUrl)
- Parameters:
authorizationServerUrl - encoded authorization server URL
execute
public final OAuthCredentialsResponse execute()
throws IOException
- Executes the HTTP request for a temporary or long-lived token.
- Returns:
- OAuth credentials response object
- Throws:
HttpResponseException - for an HTTP error code
IOException - I/O exception
createParameters
public OAuthParameters createParameters()
- Returns a new instance of the OAuth authentication provider. Subclasses may override by calling
this super implementation and then adding OAuth parameters.
Copyright © 2010-2011 Google. All Rights Reserved.