class RequiredStateTestType
Same name and namespace in other branches
- 11.x core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/RequiredStateTestType.php \Drupal\workflow_type_test\Plugin\WorkflowType\RequiredStateTestType
- 10 core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/RequiredStateTestType.php \Drupal\workflow_type_test\Plugin\WorkflowType\RequiredStateTestType
- 9 core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/RequiredStateTestType.php \Drupal\workflow_type_test\Plugin\WorkflowType\RequiredStateTestType
- main core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/RequiredStateTestType.php \Drupal\workflow_type_test\Plugin\WorkflowType\RequiredStateTestType
Test workflow type.
Plugin annotation
@WorkflowType(
id = "workflow_type_required_state_test",
label = @Translation("Required State Type Test"),
required_states = {
"fresh",
"rotten",
}
)
Hierarchy
- class \Drupal\Component\Plugin\PluginBase implements \Drupal\Component\Plugin\PluginInspectionInterface, \Drupal\Component\Plugin\DerivativeInspectionInterface
- class \Drupal\workflows\Plugin\WorkflowTypeBase implements \Drupal\workflows\WorkflowTypeInterface uses \Drupal\Core\Plugin\PluginWithFormsTrait extends \Drupal\Component\Plugin\PluginBase
- class \Drupal\workflow_type_test\Plugin\WorkflowType\RequiredStateTestType uses \Drupal\Core\StringTranslation\StringTranslationTrait extends \Drupal\workflows\Plugin\WorkflowTypeBase
- class \Drupal\workflows\Plugin\WorkflowTypeBase implements \Drupal\workflows\WorkflowTypeInterface uses \Drupal\Core\Plugin\PluginWithFormsTrait extends \Drupal\Component\Plugin\PluginBase
Expanded class hierarchy of RequiredStateTestType
File
-
core/
modules/ workflows/ tests/ modules/ workflow_type_test/ src/ Plugin/ WorkflowType/ RequiredStateTestType.php, line 20
Namespace
Drupal\workflow_type_test\Plugin\WorkflowTypeView source
class RequiredStateTestType extends WorkflowTypeBase {
use StringTranslationTrait;
/**
* {@inheritdoc}
*/
public function defaultConfiguration() {
return [
'states' => [
'fresh' => [
'label' => 'Fresh',
'weight' => 0,
],
'rotten' => [
'label' => 'Rotten',
'weight' => 1,
],
],
'transitions' => [
'rot' => [
'label' => 'Rot',
'to' => 'rotten',
'weight' => 0,
'from' => [
'fresh',
],
],
],
];
}
}
Members
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.