abstract class AAction in N1ED - Visual editor as CKEditor plugin with Bootstrap support 8.2
Abstract action - processor for any request. External code executes run() method of set config and returnes Resp* object as data structure to return via HTTP.
Hierarchy
- class \Drupal\n1ed\Flmngr\FileUploaderServer\lib\action\AAction
Expanded class hierarchy of AAction
File
- src/
Flmngr/ FileUploaderServer/ lib/ action/ AAction.php, line 10
Namespace
Drupal\n1ed\Flmngr\FileUploaderServer\lib\actionView source
abstract class AAction {
protected $config;
/**
* Sets a config.
*/
public function setConfig($config) {
$this->config = $config;
}
/**
* Returnes name of action.
*/
public abstract function getName();
/**
* Runs action.
*/
public abstract function run($req);
/**
* Validates boolean and returns default value if null.
*/
protected function validateBoolean($b, $defaultValue) {
return $b === NULL ? $defaultValue : $b;
}
/**
* Validates integer and returns default value if null.
*/
protected function validateInteger($i, $defaultValue) {
return $i === NULL ? $defaultValue : $i;
}
/**
* Validates string and returns default value if null.
*/
protected function validateString($s, $defaultValue) {
return $s === NULL ? $defaultValue : $s;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
AAction:: |
protected | property | ||
AAction:: |
abstract public | function | Returnes name of action. | 7 |
AAction:: |
abstract public | function | Runs action. | 7 |
AAction:: |
public | function | Sets a config. | |
AAction:: |
protected | function | Validates boolean and returns default value if null. | |
AAction:: |
protected | function | Validates integer and returns default value if null. | |
AAction:: |
protected | function | Validates string and returns default value if null. |