Class Zend_Oauth_Consumer

Description
  • copyright: Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
  • license: New BSD License

Located in /Oauth/Consumer.php (line 49)

Zend_Oauth
   |
   --Zend_Oauth_Consumer
Variable Summary
Method Summary
 void __construct ([array|Zend_Config $options = null])
 Zend_Oauth_Token_Access getAccessToken (array $queryData, Zend_Oauth_Token_Request $token, [string $httpMethod = null], [Zend_Oauth_Http_AccessToken $request = null])
 string getRedirectUrl ([ $customServiceParameters = null], [Zend_Oauth_Token_Request $token = null], [Zend_Oauth_Http_UserAuthorization $redirect = null])
 Zend_Oauth_Token_Request getRequestToken ([ $customServiceParameters = null], [null|string $httpMethod = null], [Zend_Oauth_Http_RequestToken $request = null])
 void redirect ([ $customServiceParameters = null], [Zend_Oauth_Http_UserAuthorization $request = null])
 mixed __call (string $method,  $args)
Variables
mixed $switcheroo = false (line 51)
  • access: public
Zend_Oauth_Token_Access $_accessToken = null (line 65)

Access token retrieved from OAuth Provider

  • access: protected
Zend_Oauth_Config $_config = null (line 70)
  • access: protected
Zend_Oauth_Token_Request $_requestToken = null (line 58)

Request Token retrieved from OAuth Provider

  • access: protected

Inherited Variables

Inherited from Zend_Oauth

Zend_Oauth::$httpClient
Methods
Constructor __construct (line 79)

Constructor; create a new object with an optional array|Zend_Config instance containing initialising options.

  • access: public
void __construct ([array|Zend_Config $options = null])
getAccessToken (line 178)

Retrieve an Access Token in exchange for a previously received/authorized Request Token.

  • throws: Zend_Oauth_Exception on invalid authorization token, non-matching response authorization token, or unprovided authorization token
  • access: public
Zend_Oauth_Token_Access getAccessToken (array $queryData, Zend_Oauth_Token_Request $token, [string $httpMethod = null], [Zend_Oauth_Http_AccessToken $request = null])
getLastAccessToken (line 240)

Return whatever the last Access Token retrieved was while using the current Consumer instance.

  • access: public
Zend_Oauth_Token_Access getLastAccessToken ()
getLastRequestToken (line 229)

Return whatever the last Request Token retrieved was while using the current Consumer instance.

  • access: public
Zend_Oauth_Token_Request getLastRequestToken ()
getRedirectUrl (line 132)

After a Request Token is retrieved, the user may be redirected to the OAuth Provider to authorize the application's access to their protected resources - the redirect URL being provided by this method.

Once the user has authorized the application for access, they are redirected back to the application which can now exchange the previous Request Token for a fully authorized Access Token.

  • access: public
string getRedirectUrl ([ $customServiceParameters = null], [Zend_Oauth_Token_Request $token = null], [Zend_Oauth_Http_UserAuthorization $redirect = null])
  • null|array $customServiceParameters
  • null|Zend_Oauth_Token_Request $token
  • null|Zend_OAuth_Http_UserAuthorization $redirect
getRequestToken (line 100)

Attempts to retrieve a Request Token from an OAuth Provider which is later exchanged for an authorized Access Token used to access the protected resources exposed by a web service API.

  • access: public
Zend_Oauth_Token_Request getRequestToken ([ $customServiceParameters = null], [null|string $httpMethod = null], [Zend_Oauth_Http_RequestToken $request = null])
  • null|array $customServiceParameters: Non-OAuth Provider-specified parameters
  • null|string $httpMethod
  • null|Zend_Oauth_Http_RequestToken $request
getToken (line 250)

Alias to self::getLastAccessToken()

  • access: public
redirect (line 158)

Rather than retrieve a redirect URL for use, e.g. from a controller, one may perform an immediate redirect.

Sends headers and exit()s on completion.

  • access: public
void redirect ([ $customServiceParameters = null], [Zend_Oauth_Http_UserAuthorization $request = null])
__call (line 265)

Simple Proxy to the current Zend_Oauth_Config method. It's that instance which holds all configuration methods and values this object also presents as it's API.

  • throws: Zend_Oauth_Exception if method does not exist in config object
  • access: public
mixed __call (string $method,  $args)
  • string $method
  • array $args

Inherited Methods

Inherited From Zend_Oauth

 Zend_Oauth::clearHttpClient()
 Zend_Oauth::getHttpClient()
 Zend_Oauth::setHttpClient()
Class Constants

Documentation generated on Mon, 21 Jun 2010 15:13:34 -0400 by phpDocumentor 1.4.3