You are here

public function BackendManager::__construct in Advanced Queue 8

Constructs a new BackendManager 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.

Overrides DefaultPluginManager::__construct

File

src/BackendManager.php, line 38

Class

BackendManager
Manages backend plugins.

Namespace

Drupal\advancedqueue

Code

public function __construct(\Traversable $namespaces, CacheBackendInterface $cache_backend, ModuleHandlerInterface $module_handler) {
  parent::__construct('Plugin/AdvancedQueue/Backend', $namespaces, $module_handler, BackendInterface::class, AdvancedQueueBackend::class);
  $this
    ->alterInfo('advancedqueue_backend_info');
  $this
    ->setCacheBackend($cache_backend, 'advancedqueue_backend_plugins');
}