class UnableToConnectException in Bynder 8
Same name and namespace in other branches
- 8.3 src/Exception/UnableToConnectException.php \Drupal\bynder\Exception\UnableToConnectException
- 8.2 src/Exception/UnableToConnectException.php \Drupal\bynder\Exception\UnableToConnectException
- 4.0.x src/Exception/UnableToConnectException.php \Drupal\bynder\Exception\UnableToConnectException
Exception indicating that the selected bundle does not exist.
Hierarchy
- class \Drupal\bynder\Exception\BynderException extends \Drupal\bynder\Exception\Exception uses StringTranslationTrait
- class \Drupal\bynder\Exception\UnableToConnectException
Expanded class hierarchy of UnableToConnectException
4 files declare their use of UnableToConnectException
- BynderOAuthLogin.php in src/
Controller/ BynderOAuthLogin.php - BynderSearch.php in src/
Plugin/ EntityBrowser/ Widget/ BynderSearch.php - BynderUpload.php in src/
Plugin/ EntityBrowser/ Widget/ BynderUpload.php - BynderWidgetBase.php in src/
Plugin/ EntityBrowser/ Widget/ BynderWidgetBase.php
File
- src/
Exception/ UnableToConnectException.php, line 10
Namespace
Drupal\bynder\ExceptionView source
class UnableToConnectException extends BynderException {
/**
* Constructs UnableToConnectException.
*/
public function __construct() {
$log_message = 'Unable to connect to Bynder. Check if the <a target="_blank" href=":url">configuration is set properly</a> or contact <a href=":support">support</a>.';
$log_message_args = [
':url' => Url::fromRoute('bynder.configuration_form')
->toString(),
':support' => 'mailto:support@getbynder.com',
];
$admin_message = $this
->t($log_message, $log_message_args);
$message = $this
->t('Unable to connect to Bynder. Please contact the site administrator.');
parent::__construct($message, $admin_message, $log_message, $log_message_args);
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BynderException:: |
protected | property | User-facing for admin users. | |
BynderException:: |
protected | property | Admin permission related to this exception. | 2 |
BynderException:: |
protected | property | Message to be logged in the Drupal's log. | |
BynderException:: |
protected | property | Arguments for the log message. | |
BynderException:: |
protected | property | Message level to be used when displaying the message to the user. | |
BynderException:: |
public | function | Displays message to the user. | |
BynderException:: |
public | function | Logs exception into Drupal's log. | |
StringTranslationTrait:: |
protected | property | The string translation service. | 1 |
StringTranslationTrait:: |
protected | function | Formats a string containing a count of items. | |
StringTranslationTrait:: |
protected | function | Returns the number of plurals supported by a given language. | |
StringTranslationTrait:: |
protected | function | Gets the string translation service. | |
StringTranslationTrait:: |
public | function | Sets the string translation service to use. | 2 |
StringTranslationTrait:: |
protected | function | Translates a string to the current language or to a given language. | |
UnableToConnectException:: |
public | function |
Constructs UnableToConnectException. Overrides BynderException:: |