You are here

public function AnonymizerPluginManager::__construct in General Data Protection Regulation 8

Same name and namespace in other branches
  1. 8.2 modules/anonymizer/src/Anonymizer/AnonymizerPluginManager.php \Drupal\anonymizer\Anonymizer\AnonymizerPluginManager::__construct()
  2. 3.0.x modules/anonymizer/src/Anonymizer/AnonymizerPluginManager.php \Drupal\anonymizer\Anonymizer\AnonymizerPluginManager::__construct()

Constructs an AnonymizerPluginManager object.

Parameters

\Traversable $namespaces: An object that implements \Traversable which contains the root paths keyed by the corresponding namespace to look for plugin implementations.

\Drupal\Core\Cache\CacheBackendInterface $cacheBackend: Cache backend instance to use.

\Drupal\Core\Extension\ModuleHandlerInterface $moduleHandler: The module handler.

Overrides DefaultPluginManager::__construct

File

modules/anonymizer/src/Anonymizer/AnonymizerPluginManager.php, line 33

Class

AnonymizerPluginManager
Manager class for Anonymizer plugins.

Namespace

Drupal\anonymizer\Anonymizer

Code

public function __construct(\Traversable $namespaces, CacheBackendInterface $cacheBackend, ModuleHandlerInterface $moduleHandler) {
  parent::__construct('Plugin/Anonymizer', $namespaces, $moduleHandler, AnonymizerInterface::class, Anonymizer::class);
  $this
    ->setCacheBackend($cacheBackend, 'anonymizer_plugins');
  $this
    ->alterInfo('anonymizer_info');
}