Zend Framework  1.12
Public Member Functions | Protected Attributes | List of all members
Zend_Oauth_Config Class Reference

Public Member Functions

 __construct ($options=null)
 Constructor; create a new object with an optional array|Zend_Config instance containing initialising options.
 
 setOptions (array $options)
 Parse option array or Zend_Config instance and setup options using their relevant mutators.
 
 setConsumerKey ($key)
 Set consumer key.
 
 getConsumerKey ()
 Get consumer key.
 
 setConsumerSecret ($secret)
 Set consumer secret.
 
 getConsumerSecret ()
 Get consumer secret.
 
 setSignatureMethod ($method)
 Set signature method.
 
 getSignatureMethod ()
 Get signature method.
 
 setRequestScheme ($scheme)
 Set request scheme.
 
 getRequestScheme ()
 Get request scheme.
 
 setVersion ($version)
 Set version.
 
 getVersion ()
 Get version.
 
 setCallbackUrl ($url)
 Set callback URL.
 
 getCallbackUrl ()
 Get callback URL.
 
 setSiteUrl ($url)
 Set site URL.
 
 getSiteUrl ()
 Get site URL.
 
 setRequestTokenUrl ($url)
 Set request token URL.
 
 getRequestTokenUrl ()
 Get request token URL.
 
 setAccessTokenUrl ($url)
 Set access token URL.
 
 getAccessTokenUrl ()
 Get access token URL.
 
 setUserAuthorizationUrl ($url)
 Set user authorization URL.
 
 setAuthorizeUrl ($url)
 Set authorization URL.
 
 getUserAuthorizationUrl ()
 Get user authorization URL.
 
 getAuthorizeUrl ()
 Get authorization URL.
 
 setRequestMethod ($method)
 Set request method.
 
 getRequestMethod ()
 Get request method.
 
 setRsaPublicKey (Zend_Crypt_Rsa_Key_Public $key)
 Set RSA public key.
 
 getRsaPublicKey ()
 Get RSA public key.
 
 setRsaPrivateKey (Zend_Crypt_Rsa_Key_Private $key)
 Set RSA private key.
 
 getRsaPrivateKey ()
 Get RSA private key.
 
 setToken (Zend_Oauth_Token $token)
 Set OAuth token.
 
 getToken ()
 Get OAuth token.
 
 setRealm ($realm)
 Set OAuth realm.
 
 getRealm ()
 Get OAuth realm.
 

Protected Attributes

 $_signatureMethod = 'HMAC-SHA1'
 
 $_requestScheme = Zend_Oauth::REQUEST_SCHEME_HEADER
 
 $_requestMethod = Zend_Oauth::POST
 
 $_version = '1.0'
 
 $_callbackUrl = null
 
 $_siteUrl = null
 
 $_requestTokenUrl = null
 
 $_accessTokenUrl = null
 
 $_authorizeUrl = null
 
 $_consumerKey = null
 
 $_consumerSecret = null
 
 $_rsaPrivateKey = null
 
 $_rsaPublicKey = null
 
 $_token = null
 
 $_realm = null
 

Constructor & Destructor Documentation

__construct (   $options = null)

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

Parameters
array | Zend_Config$options
Returns
void

Member Function Documentation

getAccessTokenUrl ( )

Get access token URL.

If no access token URL has been set, but a site URL has, returns the site URL with the string "/access_token" appended.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getAuthorizeUrl ( )

Get authorization URL.

If no authorization URL has been set, but a site URL has, returns the site URL with the string "/authorize" appended.

Returns
string
getCallbackUrl ( )

Get callback URL.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getConsumerKey ( )

Get consumer key.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getConsumerSecret ( )

Get consumer secret.

Returns RSA private key if set; otherwise, returns any previously set consumer secret.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getRealm ( )

Get OAuth realm.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getRequestMethod ( )

Get request method.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getRequestScheme ( )

Get request scheme.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getRequestTokenUrl ( )

Get request token URL.

If no request token URL has been set, but a site URL has, returns the site URL with the string "/request_token" appended.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getRsaPrivateKey ( )

Get RSA private key.

Returns
Zend_Crypt_Rsa_Key_Private
getRsaPublicKey ( )

Get RSA public key.

Returns
Zend_Crypt_Rsa_Key_Public
getSignatureMethod ( )

Get signature method.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getSiteUrl ( )

Get site URL.

Returns
string
getToken ( )

Get OAuth token.

Returns
Zend_Oauth_Token

Implements Zend_Oauth_Config_ConfigInterface.

getUserAuthorizationUrl ( )

Get user authorization URL.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

getVersion ( )

Get version.

Returns
string

Implements Zend_Oauth_Config_ConfigInterface.

setAccessTokenUrl (   $url)

Set access token URL.

Parameters
string$url
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionfor invalid URLs

Implements Zend_Oauth_Config_ConfigInterface.

setAuthorizeUrl (   $url)

Set authorization URL.

Parameters
string$url
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionfor invalid URLs
setCallbackUrl (   $url)

Set callback URL.

Parameters
string$url
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionfor invalid URLs

Implements Zend_Oauth_Config_ConfigInterface.

setConsumerKey (   $key)

Set consumer key.

Parameters
string$key
Returns
Zend_Oauth_Config

Implements Zend_Oauth_Config_ConfigInterface.

setConsumerSecret (   $secret)

Set consumer secret.

Parameters
string$secret
Returns
Zend_Oauth_Config

Implements Zend_Oauth_Config_ConfigInterface.

setOptions ( array  $options)

Parse option array or Zend_Config instance and setup options using their relevant mutators.

Parameters
array | Zend_Config$options
Returns
Zend_Oauth_Config

Implements Zend_Oauth_Config_ConfigInterface.

setRealm (   $realm)

Set OAuth realm.

Parameters
string$realm
Returns
Zend_Oauth_Config

Implements Zend_Oauth_Config_ConfigInterface.

setRequestMethod (   $method)

Set request method.

Parameters
string$method
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionfor invalid request methods

Implements Zend_Oauth_Config_ConfigInterface.

setRequestScheme (   $scheme)

Set request scheme.

Parameters
string$scheme
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionif invalid scheme specified, or if POSTBODY set when request method of GET is specified

Implements Zend_Oauth_Config_ConfigInterface.

setRequestTokenUrl (   $url)

Set request token URL.

Parameters
string$url
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionfor invalid URLs

Implements Zend_Oauth_Config_ConfigInterface.

setRsaPrivateKey ( Zend_Crypt_Rsa_Key_Private  $key)

Set RSA private key.

Parameters
Zend_Crypt_Rsa_Key_Private$key
Returns
Zend_Oauth_Config
setRsaPublicKey ( Zend_Crypt_Rsa_Key_Public  $key)

Set RSA public key.

Parameters
Zend_Crypt_Rsa_Key_Public$key
Returns
Zend_Oauth_Config
setSignatureMethod (   $method)

Set signature method.

Parameters
string$method
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionif unsupported signature method specified

Implements Zend_Oauth_Config_ConfigInterface.

setSiteUrl (   $url)

Set site URL.

Parameters
string$url
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionfor invalid URLs
setToken ( Zend_Oauth_Token  $token)

Set OAuth token.

Parameters
Zend_Oauth_Token$token
Returns
Zend_Oauth_Config

Implements Zend_Oauth_Config_ConfigInterface.

setUserAuthorizationUrl (   $url)

Set user authorization URL.

Parameters
string$url
Returns
Zend_Oauth_Config
Exceptions
Zend_Oauth_Exceptionfor invalid URLs

Implements Zend_Oauth_Config_ConfigInterface.

setVersion (   $version)

Set version.

Parameters
string$version
Returns
Zend_Oauth_Config

Implements Zend_Oauth_Config_ConfigInterface.

Member Data Documentation

$_accessTokenUrl = null
protected
$_authorizeUrl = null
protected
$_callbackUrl = null
protected
$_consumerKey = null
protected
$_consumerSecret = null
protected
$_realm = null
protected
$_requestMethod = Zend_Oauth::POST
protected
$_requestScheme = Zend_Oauth::REQUEST_SCHEME_HEADER
protected
$_requestTokenUrl = null
protected
$_rsaPrivateKey = null
protected
$_rsaPublicKey = null
protected
$_signatureMethod = 'HMAC-SHA1'
protected
$_siteUrl = null
protected
$_token = null
protected
$_version = '1.0'
protected