serviceName = $this->getParam(self::$SERVICE_PARAM, ""); $this->tokenName = $this->getParam(self::$TOKEN_PARAM, ""); $this->requestToken = $this->getParam(self::$REQUEST_TOKEN_PARAM, null); $this->requestTokenSecret = $this->getParam(self::$REQUEST_TOKEN_SECRET_PARAM, null); $this->origClientState = $this->getParam(self::$CLIENT_STATE_PARAM, null); $this->bypassSpecCache = $this->parseBypassSpecCacheParam(); } private function getParam($name, $def) { $val = null; if (isset($_REQUEST[$name])) { $val = $_REQUEST[$name]; } if ($val == null) { $val = $def; } return $val; } public function getBypassSpecCache() { return $this->bypassSpecCache; } public function getRequestToken() { return $this->requestToken; } public function getRequestTokenSecret() { return $this->requestTokenSecret; } public static function parseBypassSpecCacheParam() { if (isset($_REQUEST[self::$BYPASS_SPEC_CACHE_PARAM])) { return "1" == $_REQUEST[self::$BYPASS_SPEC_CACHE_PARAM]; } return false; } public function getServiceName() { return $this->serviceName; } public function getTokenName() { return $this->tokenName; } public function getOrigClientState() { return $this->origClientState; } }