You are here

public function SettingObjectPluginManager::__construct in Fasttoggle 8.2

Creates the discovery 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 $cache_backend: Cache backend instance to use.

\Drupal\Core\Extension\ModuleHandlerInterface $module_handler: The module handler to invoke the alter hook with.

Overrides DefaultPluginManager::__construct

File

src/SettingObjectPluginManager.php, line 33
Contains \Drupal\fasttoggle\FasttoggleObjectPluginManager.

Class

SettingObjectPluginManager
Manages Fasttoggle Manged Object plugins.

Namespace

Drupal\fasttoggle

Code

public function __construct(\Traversable $namespaces, CacheBackendInterface $cache_backend, ModuleHandlerInterface $module_handler) {
  $subdir = 'Plugin/SettingObject';
  $plugin_interface = 'Drupal\\fasttoggle\\Plugin\\SettingObject\\SettingObjectInterface';
  $plugin_definition_annotation_name = 'Drupal\\Component\\Annotation\\Plugin';
  parent::__construct($subdir, $namespaces, $module_handler, $plugin_interface, $plugin_definition_annotation_name);
  $this
    ->alterInfo('fasttoggle_setting_object_info');
  $this
    ->setCacheBackend($cache_backend, 'fasttoggle_setting_object_info');
}