protected function CKEditor5PluginManager::getDiscovery in Drupal 10
Gets the plugin discovery.
Return value
\Drupal\Component\Plugin\Discovery\DiscoveryInterface
Overrides DefaultPluginManager::getDiscovery
File
- core/
modules/ ckeditor5/ src/ Plugin/ CKEditor5PluginManager.php, line 56
Class
- CKEditor5PluginManager
- Provides a CKEditor5 plugin manager.
Namespace
Drupal\ckeditor5\PluginCode
protected function getDiscovery() {
if (!$this->discovery) {
$discovery = new AnnotatedClassDiscovery($this->subdir, $this->namespaces, $this->pluginDefinitionAnnotationName, $this->additionalAnnotationNamespaces);
$discovery = new YamlDiscoveryDecorator($discovery, 'ckeditor5', $this->moduleHandler
->getModuleDirectories());
// Note: adding translatable properties here is impossible because it only
// supports top-level properties.
// @see \Drupal\ckeditor5\Plugin\CKEditor5PluginDefinition::label()
$discovery = new AnnotationBridgeDecorator($discovery, $this->pluginDefinitionAnnotationName);
$this->discovery = $discovery;
}
return $this->discovery;
}