| Package | com.yahoo.oauth |
| Class | public class OAuthConnection |
| Property | Defined by | ||
|---|---|---|---|
| consumer : OAuthConsumer
The OAuth consumer.
| OAuthConnection | ||
| realm : String
The service provider realm using in an "Authorization: OAuth..." header.
| OAuthConnection | ||
| requestType : String
The OAuth request type.
| OAuthConnection | ||
| signatureMethod : IOAuthSignatureMethod
The signature method to be used when signing the request.
| OAuthConnection | ||
| token : OAuthToken
The optional OAuth token.
| OAuthConnection | ||
| useExplicitEncoding : Boolean = true
Determines if the request parameters in the signature base string should be encoded using
encodeURIComponent. | OAuthConnection | ||
| Method | Defined by | ||
|---|---|---|---|
|
Creates a new OAuthConnection object.
| OAuthConnection | ||
|
asyncRequest(httpMethod:String, url:String, callback:Object, args:Object = null, headers:Array = null):URLRequest
Sends a new HTTP request directly.
| OAuthConnection | ||
|
asyncRequestSigned(httpMethod:String, url:String, callback:Object, args:Object = null, headers:Array = null):URLRequest
Signs and sends a HTTP request using the OAuth consumer and token and the provided arguments.
| OAuthConnection | ||
|
[static]
Returns a new OAuthConnection object for the specified OAuth consumer and token.
| OAuthConnection | ||
|
signRequest(httpMethod:String, url:String, args:Object = null):*
Signs a request using the provided method, URL and arguments.
| OAuthConnection | ||
| consumer | property |
consumer:OAuthConsumer [read-write]The OAuth consumer.
Implementation public function get consumer():OAuthConsumer
public function set consumer(value:OAuthConsumer):void
| realm | property |
realm:String [read-write]The service provider realm using in an "Authorization: OAuth..." header.
Implementation public function get realm():String
public function set realm(value:String):void
| requestType | property |
requestType:String [read-write]The OAuth request type.
Implementation public function get requestType():String
public function set requestType(value:String):void
| signatureMethod | property |
signatureMethod:IOAuthSignatureMethod [read-write]The signature method to be used when signing the request.
Implementation public function get signatureMethod():IOAuthSignatureMethod
public function set signatureMethod(value:IOAuthSignatureMethod):void
| token | property |
token:OAuthToken [read-write]The optional OAuth token.
Implementation public function get token():OAuthToken
public function set token(value:OAuthToken):void
| useExplicitEncoding | property |
public var useExplicitEncoding:Boolean = true
Determines if the request parameters in the signature base string should be encoded using encodeURIComponent.
| OAuthConnection | () | constructor |
public function OAuthConnection()Creates a new OAuthConnection object.
| asyncRequest | () | method |
public function asyncRequest(httpMethod:String, url:String, callback:Object, args:Object = null, headers:Array = null):URLRequestSends a new HTTP request directly.
ParametershttpMethod:String — The URLRequestMethod to use in the request.
|
|
url:String — The URL to call in the URLRequest
|
|
callback:Object — An Object containing success, failure and security callback functions.
|
|
args:Object (default = null) — An Object, String, URLVariables or ByteArray to include in the URLRequest.data object.
|
|
headers:Array (default = null) — An Array of valid URLRequestHeader objects to be set in the URLRequest.requestHeaders property.
|
URLRequest — The URLRequest object generated.
|
See also
| asyncRequestSigned | () | method |
public function asyncRequestSigned(httpMethod:String, url:String, callback:Object, args:Object = null, headers:Array = null):URLRequestSigns and sends a HTTP request using the OAuth consumer and token and the provided arguments.
ParametershttpMethod:String — The URLRequestMethod to use in the request.
|
|
url:String — The URL to call in the URLRequest
|
|
callback:Object — An Object containing success, failure and security callback functions.
|
|
args:Object (default = null) — An Object, String, URLVariables or ByteArray to include in the URLRequest.data object.
|
|
headers:Array (default = null) — An array of valid URLRequestHeader objects to be set in the URLRequest.requestHeaders property.
|
URLRequest — The URLRequest object generated.
|
See also
| fromConsumerAndToken | () | method |
public static function fromConsumerAndToken(consumer:OAuthConsumer, token:OAuthToken = null):OAuthConnectionReturns a new OAuthConnection object for the specified OAuth consumer and token.
Parametersconsumer:OAuthConsumer — A consumer containing a key and secret used to identify an application making a request to the service provider.
|
|
token:OAuthToken (default = null) — An optional token containing a key and secret, used for signing three-legged requests.
|
OAuthConnection —
A new OAuthConnection object.
|
| signRequest | () | method |
public function signRequest(httpMethod:String, url:String, args:Object = null):*Signs a request using the provided method, URL and arguments.
ParametershttpMethod:String — The URLRequestMethod to use in the request.
|
|
url:String — The URL to request.
|
|
args:Object (default = null) — An object containing the parameters to be signed.
|
* — An object whose type is determined by the value of requestType.
|