MDL-42666 oauthlib: Getter methods for accesstoken, client id and secret

This commit is contained in:
Frederic Massart
2013-11-06 11:22:34 +08:00
parent b04cc1f3a7
commit c800a57c7d
+33
View File
@@ -617,6 +617,39 @@ abstract class oauth2_client extends curl {
return null;
}
/**
* Get access token.
*
* This is just a getter to read the private property.
*
* @return string
*/
public function get_accesstoken() {
return $this->accesstoken;
}
/**
* Get the client ID.
*
* This is just a getter to read the private property.
*
* @return string
*/
public function get_clientid() {
return $this->clientid;
}
/**
* Get the client secret.
*
* This is just a getter to read the private property.
*
* @return string
*/
public function get_clientsecret() {
return $this->clientsecret;
}
/**
* Should HTTP GET be used instead of POST?
* Some APIs do not support POST and want oauth to use