class YamlCacheCollectorDiscovery

Same name in this branch
  1. 11.x core/lib/Drupal/Core/Discovery/YamlCacheCollectorDiscovery.php \Drupal\Core\Discovery\YamlCacheCollectorDiscovery
Same name and namespace in other branches
  1. main core/lib/Drupal/Core/Discovery/YamlCacheCollectorDiscovery.php \Drupal\Core\Discovery\YamlCacheCollectorDiscovery
  2. main core/lib/Drupal/Core/Plugin/Discovery/YamlCacheCollectorDiscovery.php \Drupal\Core\Plugin\Discovery\YamlCacheCollectorDiscovery

Extends YamlDiscovery to add a file parsing cache collector.

Hierarchy

Expanded class hierarchy of YamlCacheCollectorDiscovery

4 files declare their use of YamlCacheCollectorDiscovery
LocalActionManager.php in core/lib/Drupal/Core/Menu/LocalActionManager.php
LocalTaskIntegrationTestBase.php in core/tests/Drupal/Tests/Core/Menu/LocalTaskIntegrationTestBase.php
LocalTaskManager.php in core/lib/Drupal/Core/Menu/LocalTaskManager.php
MenuLinkManager.php in core/lib/Drupal/Core/Menu/MenuLinkManager.php

File

core/lib/Drupal/Core/Plugin/Discovery/YamlCacheCollectorDiscovery.php, line 13

Namespace

Drupal\Core\Plugin\Discovery
View source
class YamlCacheCollectorDiscovery extends YamlDiscovery {
  
  /**
   * Construct a YamlDiscovery object.
   *
   * @param string $name
   *   The file name suffix to use for discovery; for example, 'test' will
   *   become 'MODULE.test.yml'.
   * @param array $directories
   *   An array of directories to scan.
   * @param Drupal\Core\Cache\CacheCollectorInterface $yamlCacheCollector
   *   A YamlCacheCollector instance.
   */
  public function __construct(string $name, array $directories, CacheCollectorInterface $yamlCacheCollector) {
    $this->discovery = new YamlCollector($name, $directories, $yamlCacheCollector);
  }

}

Members

Title Sort descending Modifiers Object type Summary Overriden Title Overrides
DiscoveryTrait::doGetDefinition protected function Gets a specific plugin definition.
DiscoveryTrait::getDefinition public function 3
DiscoveryTrait::hasDefinition public function
YamlCacheCollectorDiscovery::__construct public function Construct a YamlDiscovery object. Overrides YamlDiscovery::__construct
YamlDiscovery::$discovery protected property YAML file discovery and parsing handler.
YamlDiscovery::$translatableProperties protected property Contains an array of translatable properties passed along to t().
YamlDiscovery::addTranslatableProperty public function Set one of the YAML values as being translatable.
YamlDiscovery::getDefinitions public function Gets the definition of all plugins for this type. Overrides DiscoveryTrait::getDefinitions 1

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