public function ContentProcessorPluginManager::__construct in YAML Content 8.2
Creates the discovery object.
Parameters
string|bool $subdir: The plugin's subdirectory, for example Plugin/views/filter.
\Traversable $namespaces: An object that implements \Traversable which contains the root paths keyed by the corresponding namespace to look for plugin implementations.
\Drupal\Core\Extension\ModuleHandlerInterface $module_handler: The module handler.
string|null $plugin_interface: (optional) The interface each plugin should implement.
string $plugin_definition_annotation_name: (optional) The name of the annotation that contains the plugin definition. Defaults to 'Drupal\Component\Annotation\Plugin'.
string[] $additional_annotation_namespaces: (optional) Additional namespaces to scan for annotation definitions.
Overrides DefaultPluginManager::__construct
File
- src/
ContentProcessorPluginManager.php, line 17
Class
- ContentProcessorPluginManager
- A plugin manager service for ContentProcessor plugin implementations.
Namespace
Drupal\yaml_contentCode
public function __construct(\Traversable $namespaces, CacheBackendInterface $cache_backend, ModuleHandlerInterface $module_handler) {
$subdir = 'Plugin/YamlContent';
$plugin_interface = 'Drupal\\yaml_content\\ContentProcessorInterface';
$plugin_definition_annotation_name = 'Drupal\\yaml_content\\Annotation\\ContentProcessor';
parent::__construct($subdir, $namespaces, $module_handler, $plugin_interface, $plugin_definition_annotation_name);
$this
->alterInfo('yaml_content_processor_info');
$this
->setCacheBackend($cache_backend, 'yaml_content_processor_info');
}