class InvalidOauth2ClientException in OAuth2 Client 8.3
Same name and namespace in other branches
- 8.2 src/Exception/InvalidOauth2ClientException.php \Drupal\oauth2_client\Exception\InvalidOauth2ClientException
Exception thrown when trying to retrieve a non-existent OAuth2 Client.
Hierarchy
- class \Drupal\oauth2_client\Exception\InvalidOauth2ClientException extends \Drupal\oauth2_client\Exception\Exception
Expanded class hierarchy of InvalidOauth2ClientException
1 file declares its use of InvalidOauth2ClientException
- Oauth2ClientServiceBase.php in src/
Service/ Oauth2ClientServiceBase.php
File
- src/
Exception/ InvalidOauth2ClientException.php, line 8
Namespace
Drupal\oauth2_client\ExceptionView source
class InvalidOauth2ClientException extends \Exception {
/**
* Constructs an InvalidOauth2ClientException object.
*
* @param string $invalidClientId
* The passed Oauth2 Client ID that was found to be invalid.
* @param string $message
* The Exception message to throw.
* @param int $code
* The Exception code.
* @param \Throwable $previous
* The previous exception used for the exception chaining.
*/
public function __construct($invalidClientId, $message = "", $code = 0, \Throwable $previous = NULL) {
if ($message == "") {
if (is_scalar($invalidClientId)) {
$message = "The OAuth2 Client plugin '" . $invalidClientId . "' does not exist";
}
else {
$message = 'An invalid value was passed for the OAuth2 Plugin ID';
}
}
parent::__construct($message, $code, $previous);
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
InvalidOauth2ClientException:: |
public | function | Constructs an InvalidOauth2ClientException object. |