Class JOAuth2Client

Description

Joomla Platform class for interacting with an OAuth 2.0 server.

  • since: 12.3

Located in /libraries/joomla/oauth2/client.php (line 19)


	
			
Direct descendents
Class Description
 class JFacebookOAuth Joomla Platform class for generating Facebook API access token.
Variable Summary
Method Summary
 JOAuth2Client __construct ([JRegistry $options = null], [JHttp $http = null], [JInput $input = null], [JApplicationWeb $application = null])
 string authenticate ()
 mixed getOption (string $key)
 array getToken ()
 boolean isAuthenticated ()
 string query (string $url, [mixed $data = null], [array $headers = array()], [string $method = 'get'], [int $timeout = null])
 array refreshToken ([string $token = null])
 JOAuth2Client setOption (string $key, mixed $value)
 JOAuth2Client setToken (array $value)
Variables
JApplicationWeb $application (line 43)
  • var: The application object to send HTTP headers for redirects.
  • since: 12.3
  • access: protected
JHttp $http (line 31)
  • var: The HTTP client object to use in sending HTTP requests.
  • since: 12.3
  • access: protected
JInput $input (line 37)
  • var: The input object to use in retrieving GET/POST data.
  • since: 12.3
  • access: protected
JRegistry $options (line 25)
  • var: Options for the JOAuth2Client object.
  • since: 12.3
  • access: protected

Redefined in descendants as:
Methods
Constructor __construct (line 55)

Constructor.

  • since: 12.3
  • access: public
JOAuth2Client __construct ([JRegistry $options = null], [JHttp $http = null], [JInput $input = null], [JApplicationWeb $application = null])

Redefined in descendants as:
authenticate (line 71)

Get the access token or redict to the authentication URL.

  • return: The access token
  • since: 12.3
  • throws: RuntimeException
  • access: public
string authenticate ()
createUrl (line 144)

Create the URL for authentication.

  • return: The HTTP response
  • since: 12.3
  • throws: InvalidArgumentException
  • access: public
JHttpResponse createUrl ()
getOption (line 271)

Get an option from the JOAuth2Client instance.

  • return: The option value
  • since: 12.3
  • access: public
mixed getOption (string $key)
  • string $key: The name of the option to get
getToken (line 300)

Get the access token from the JOAuth2Client instance.

  • return: The access token
  • since: 12.3
  • access: public
array getToken ()
isAuthenticated (line 118)

Verify if the client has been authenticated

  • return: Is authenticated
  • since: 12.3
  • access: public
boolean isAuthenticated ()
query (line 207)

Send a signed Oauth request.

  • return: The URL.
  • throws: InvalidArgumentException
  • throws: RuntimeException
  • since: 12.3
  • access: public
string query (string $url, [mixed $data = null], [array $headers = array()], [string $method = 'get'], [int $timeout = null])
  • string $url: The URL forf the request.
  • mixed $data: The data to include in the request
  • array $headers: The headers to send with the request
  • string $method: The method with which to send the request
  • int $timeout: The timeout for the request
refreshToken (line 337)

Refresh the access token instance.

  • return: The new access token
  • throws: Exception
  • throws: RuntimeException
  • since: 12.3
  • access: public
array refreshToken ([string $token = null])
  • string $token: The refresh token
setOption (line 286)

Set an option for the JOAuth2Client instance.

  • return: This object for method chaining
  • since: 12.3
  • access: public
JOAuth2Client setOption (string $key, mixed $value)
  • string $key: The name of the option to set
  • mixed $value: The option value to set
setToken (line 314)

Set an option for the JOAuth2Client instance.

  • return: This object for method chaining
  • since: 12.3
  • access: public
JOAuth2Client setToken (array $value)
  • array $value: The access token

Documentation generated on Tue, 19 Nov 2013 14:55:51 +0100 by phpDocumentor 1.4.3