From a58bceb4aad2c356de7196c49a571a0f9da84eae Mon Sep 17 00:00:00 2001 From: GaryJones Date: Thu, 22 Nov 2012 13:17:23 +0000 Subject: [PATCH] Make callback_url property protected, and add get/set methods. --- src/GaryJones/OAuth/Client.php | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/src/GaryJones/OAuth/Client.php b/src/GaryJones/OAuth/Client.php index fb163b1..fd8dfcf 100644 --- a/src/GaryJones/OAuth/Client.php +++ b/src/GaryJones/OAuth/Client.php @@ -19,6 +19,13 @@ namespace GaryJones\OAuth; */ class Client extends Credential { + /** + * URL to which authorized requests will redirect to. + * + * @var string + */ + protected $callback_url; + /** * Constructs a new client object and populates the required parameters. * @@ -30,6 +37,26 @@ class Client extends Credential { $this->setKey($key); $this->setSecret($secret); + $this->setCallbackUrl($callback_url); + } + + /** + * Get the callback URL. + * + * @return string + */ + public function getCallbackUrl() + { + return $this->callback_url; + } + + /** + * Set the callbackURL + * + * @param string $callback_url + */ + public function setCallbackUrl($callback_url) + { $this->callback_url = $callback_url; } }