function CKEditor5PluginDefinition::getConditions
Same name in other branches
- 9 core/modules/ckeditor5/src/Plugin/CKEditor5PluginDefinition.php \Drupal\ckeditor5\Plugin\CKEditor5PluginDefinition::getConditions()
- 10 core/modules/ckeditor5/src/Plugin/CKEditor5PluginDefinition.php \Drupal\ckeditor5\Plugin\CKEditor5PluginDefinition::getConditions()
Gets the list of conditions to enable this plugin.
Return value
array An array of conditions.
Throws
\LogicException When called on a plugin definition that has no conditions.
See also
\Drupal\ckeditor5\Annotation\DrupalAspectsOfCKEditor5Plugin::$conditions
File
-
core/
modules/ ckeditor5/ src/ Plugin/ CKEditor5PluginDefinition.php, line 372
Class
- CKEditor5PluginDefinition
- Provides an implementation of a CKEditor 5 plugin definition.
Namespace
Drupal\ckeditor5\PluginCode
public function getConditions() : array {
if (!$this->hasConditions()) {
throw new \LogicException('::getConditions() should only be called if ::hasConditions() returns TRUE.');
}
return $this->drupal['conditions'];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.