[ class tree: Gliffy ] [ index: Gliffy ] [ all elements ]

Class: OAuthRequest

Source Location: /OAuth.php

Class Overview




Variables

Methods



Class Details

[line 174]


[ Top ]


Class Variables

static $version =  '1.0'

[line 180]



Tags:

access:  public

Type:   mixed


[ Top ]

$base_string =

[line 179]



Tags:

access:  public

Type:   mixed


[ Top ]



Class Methods


static method from_consumer_and_token [line 228]

static void from_consumer_and_token( $consumer, $token, $http_method, $http_url, [ $parameters = NULL])

pretty much a helper function to set up the request



Tags:

access:  public


Parameters:

   $consumer  
   $token  
   $http_method  
   $http_url  
   $parameters  

[ Top ]

static method from_request [line 193]

static void from_request( [ $http_method = NULL], [ $http_url = NULL], [ $parameters = NULL])

attempt to build up a request from what was passed to the server



Tags:

access:  public


Parameters:

   $http_method  
   $http_url  
   $parameters  

[ Top ]

constructor __construct [line 182]

OAuthRequest __construct( $http_method, $http_url, [ $parameters = NULL])



Parameters:

   $http_method  
   $http_url  
   $parameters  

[ Top ]

method build_signature [line 409]

void build_signature( $signature_method, $consumer, $token)



Tags:

access:  public


Parameters:

   $signature_method  
   $consumer  
   $token  

[ Top ]

method get_normalized_http_method [line 328]

void get_normalized_http_method( )

just uppercases the http method



Tags:

access:  public


[ Top ]

method get_normalized_http_url [line 336]

void get_normalized_http_url( )

parses the url and rebuilds it to be

scheme://host/path




Tags:

access:  public


[ Top ]

method get_parameter [line 246]

void get_parameter( $name)



Tags:

access:  public


Parameters:

   $name  

[ Top ]

method get_parameters [line 250]

void get_parameters( )



Tags:

access:  public


[ Top ]

method get_signable_parameters [line 266]

string get_signable_parameters( )

Returns the normalized parameters of the request

This will be all (except oauth_signature) parameters, sorted first by key, and if duplicate keys, then by value.

The returned string will be all the key=value pairs concated by &.




Tags:

access:  public


[ Top ]

method get_signature_base_string [line 309]

void get_signature_base_string( )

Returns the base string of this request

The base string defined as the method, the url and the parameters (normalized), each urlencoded and the concated with &.




Tags:

access:  public


[ Top ]

method set_parameter [line 242]

void set_parameter( $name, $value)



Tags:

access:  public


Parameters:

   $name  
   $value  

[ Top ]

method sign_request [line 403]

void sign_request( $signature_method, $consumer, $token)



Tags:

access:  public


Parameters:

   $signature_method  
   $consumer  
   $token  

[ Top ]

method to_header [line 387]

void to_header( )

builds the Authorization: header



Tags:

access:  public


[ Top ]

method to_postdata [line 369]

void to_postdata( )

builds the data one would send in a POST request

TODO(morten.fangel): this function might be easily replaced with http_build_query() and corrections for rfc3986 compatibility.. but not sure




Tags:

access:  public


[ Top ]

method to_url [line 356]

void to_url( )

builds a url usable for a GET request



Tags:

access:  public


[ Top ]

method __toString [line 398]

void __toString( )



Tags:

access:  public


[ Top ]


Documentation generated on Mon, 13 Jul 2009 19:54:35 -0500 by phpDocumentor 1.4.1