API Documentation

Oauth/Http/RequestToken.php

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

category
Zend  
copyright
Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)  
license
New BSD License  
package
Zend_Oauth  
version
$Id: RequestToken.php 23775 2011-03-01 17:25:24Z ralph $  

\Zend_Oauth_Http_RequestToken

Extends from
\Zend_Oauth_Http
category
Zend  
copyright
Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)  
license
New BSD License  
package
Zend_Oauth  

Properties

Propertyprotected\Zend_Http_Client  $_httpClient= 'null'

Singleton instance if required of the HTTP client

Default valuenullDetails
Type
\Zend_Http_Client

Methods

methodpublic__construct( \Zend_Oauth_Consumer $consumer, null|array $parameters = null, null|\Zend_Oauth_Http_Utility $utility = null ) : void

Constructor

Inherited from: \Zend_Oauth_Http::__construct()
Parameters
Name Type Description
$consumer \Zend_Oauth_Consumer
$parameters null|array
$utility null|\Zend_Oauth_Http_Utility
methodprotected_assessRequestAttempt(  $response = null ) : void

Manages the switch from OAuth request scheme to another lower preference scheme during a request cycle.

Inherited from: \Zend_Oauth_Http::_assessRequestAttempt()
Parameters
Name Type Description
$response Zend_Http_Response
Throws
Exception Description
\Zend_Oauth_Exception if unable to retrieve valid token response
methodprotected_attemptRequest( array $params ) : \Zend_Http_Response

Attempt a request based on the current configured OAuth Request Scheme and return the resulting HTTP Response.

Parameters
Name Type Description
$params array
Returns
Type Description
\Zend_Http_Response
methodprotected_toAuthorizationHeader( array $params, string $realm = null ) : string

Generates a valid OAuth Authorization header based on the provided parameters and realm.

Inherited from: \Zend_Oauth_Http::_toAuthorizationHeader()
Parameters
Name Type Description
$params array
$realm string
Returns
Type Description
string
methodpublicassembleParams( ) : array

Assemble all parameters for an OAuth Request Token request.

Returns
Type Description
array
methodpublicexecute( ) : \Zend_Oauth_Token_Request

Initiate a HTTP request to retrieve a Request Token.

Returns
Type Description
\Zend_Oauth_Token_Request
methodpublicgetConsumer( ) : \Zend_Oauth_Consumer

Return the Consumer instance in use.

Inherited from: \Zend_Oauth_Http::getConsumer()
Returns
Type Description
\Zend_Oauth_Consumer
methodpublicgetMethod( ) : string

Preferred HTTP request method accessor.

Inherited from: \Zend_Oauth_Http::getMethod()
Returns
Type Description
string
methodpublicgetParameters( ) : array

Accessor for an array of custom parameters.

Inherited from: \Zend_Oauth_Http::getParameters()
Returns
Type Description
array
methodpublicgetRequestSchemeHeaderClient( array $params ) : \Zend_Http_Client

Generate and return a HTTP Client configured for the Header Request Scheme specified by OAuth, for use in requesting a Request Token.

Parameters
Name Type Description
$params array
Returns
Type Description
\Zend_Http_Client
methodpublicgetRequestSchemePostBodyClient( array $params ) : \Zend_Http_Client

Generate and return a HTTP Client configured for the POST Body Request Scheme specified by OAuth, for use in requesting a Request Token.

Parameters
Name Type Description
$params array
Returns
Type Description
\Zend_Http_Client
methodpublicgetRequestSchemeQueryStringClient( array $params, string $url ) : \Zend_Http_Client

Return an instance of Zend_Http_Client configured to use the Query String scheme for an OAuth driven HTTP request.

Inherited from: \Zend_Oauth_Http::getRequestSchemeQueryStringClient()
Parameters
Name Type Description
$params array
$url string
Returns
Type Description
\Zend_Http_Client
methodpublicsetMethod( string $method ) : \Zend_Oauth_Http

Set a preferred HTTP request method.

Inherited from: \Zend_Oauth_Http::setMethod()
Parameters
Name Type Description
$method string
Returns
Type Description
\Zend_Oauth_Http
methodpublicsetParameters( array $customServiceParameters ) : \Zend_Oauth_Http

Mutator to set an array of custom parameters for the HTTP request.

Inherited from: \Zend_Oauth_Http::setParameters()
Parameters
Name Type Description
$customServiceParameters array
Returns
Type Description
\Zend_Oauth_Http
methodpublicstartRequestCycle( array $params ) : \Zend_Http_Response

Commence a request cycle where the current HTTP method and OAuth request scheme set an upper preferred HTTP request style and where failures generate a new HTTP request style further down the OAuth preference list for OAuth Request Schemes.

Inherited from: \Zend_Oauth_Http::startRequestCycle()

On success, return the Request object that results for processing.

Parameters
Name Type Description
$params array
Returns
Type Description
\Zend_Http_Response
Throws
Exception Description
\Zend_Oauth_Exception on HTTP request errors
Details
todo
Remove cycling?; Replace with upfront do-or-die configuration  
Documentation was generated by DocBlox 0.13.3.