function CachedDiscoveryClearer::addCachedDiscovery

Adds a plugin manager to the active list.

Parameters

\Drupal\Component\Plugin\Discovery\CachedDiscoveryInterface $cached_discovery: An object that implements the cached discovery interface, typically a plugin manager.

Overrides CachedDiscoveryClearerInterface::addCachedDiscovery

File

core/lib/Drupal/Core/Plugin/CachedDiscoveryClearer.php, line 22

Class

CachedDiscoveryClearer
Defines a class which is capable of clearing the cache on plugin managers.

Namespace

Drupal\Core\Plugin

Code

public function addCachedDiscovery(CachedDiscoveryInterface $cached_discovery) {
  $this->cachedDiscoveries[] = $cached_discovery;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.