You are here

protected function MigrateSourcePluginManager::getDiscovery in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/migrate/src/Plugin/MigrateSourcePluginManager.php \Drupal\migrate\Plugin\MigrateSourcePluginManager::getDiscovery()

Gets the plugin discovery.

Return value

\Drupal\Component\Plugin\Discovery\DiscoveryInterface

Overrides DefaultPluginManager::getDiscovery

File

core/modules/migrate/src/Plugin/MigrateSourcePluginManager.php, line 44

Class

MigrateSourcePluginManager
Plugin manager for migrate source plugins.

Namespace

Drupal\migrate\Plugin

Code

protected function getDiscovery() {
  if (!$this->discovery) {
    $discovery = new AnnotatedClassDiscoveryAutomatedProviders($this->subdir, $this->namespaces, $this->pluginDefinitionAnnotationName, $this->additionalAnnotationNamespaces);
    $this->discovery = new ContainerDerivativeDiscoveryDecorator($discovery);
  }
  return $this->discovery;
}