class ValidationError in Backup and Migrate 5.0.x
@package Drupal\backup_migrate\Core\Config
Hierarchy
- class \Drupal\backup_migrate\Core\Config\ValidationError implements ValidationErrorInterface
Expanded class hierarchy of ValidationError
File
- src/
Core/ Config/ ValidationError.php, line 10
Namespace
Drupal\backup_migrate\Core\ConfigView source
class ValidationError implements ValidationErrorInterface {
/**
* @var string
*/
protected $fieldKey = '';
/**
* @var string
*/
protected $message = '';
/**
* @var array
*/
protected $replacement = [];
/**
* @param $field_key
* @param $message
* @param array $replacement
*/
public function __construct($field_key, $message, array $replacement = []) {
$this->fieldKey = $field_key;
$this->message = $message;
$this->replacement = $replacement;
}
/**
* @return string
*/
public function getMessage() {
return $this->message;
}
/**
* @return array
*/
public function getReplacement() {
return $this->replacement;
}
/**
* @return string
*/
public function getFieldKey() {
return $this->fieldKey;
}
/**
* String representation of the exception.
*
* @return string
* The string representation of the exception.
*/
public function __toString() {
return strtr($this
->getMessage(), $this
->getReplacement());
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ValidationError:: |
protected | property | ||
ValidationError:: |
protected | property | ||
ValidationError:: |
protected | property | ||
ValidationError:: |
public | function |
Overrides ValidationErrorInterface:: |
|
ValidationError:: |
public | function |
Overrides ValidationErrorInterface:: |
|
ValidationError:: |
public | function |
Overrides ValidationErrorInterface:: |
|
ValidationError:: |
public | function | ||
ValidationError:: |
public | function | String representation of the exception. |