class ViewsPluginManager

Plugin type manager for all views plugins.

Hierarchy

Expanded class hierarchy of ViewsPluginManager

1 file declares its use of ViewsPluginManager
ViewAddFormController.php in drupal/core/modules/views_ui/lib/Drupal/views_ui/ViewAddFormController.php
Contains Drupal\views_ui\ViewAddFormController.
1 string reference to 'ViewsPluginManager'
views.services.yml in drupal/core/modules/views/views.services.yml
drupal/core/modules/views/views.services.yml

File

drupal/core/modules/views/lib/Drupal/views/Plugin/ViewsPluginManager.php, line 22
Contains \Drupal\views\Plugin\ViewsPluginManager.

Namespace

Drupal\views\Plugin
View source
class ViewsPluginManager extends PluginManagerBase {

  /**
   * Constructs a ViewsPluginManager object.
   *
   * @param string $type
   *   The plugin type, for example filter.
   * @param \Traversable $namespaces
   *   An object that implements \Traversable which contains the root paths
   *   keyed by the corresponding namespace to look for plugin implementations,
   */
  public function __construct($type, \Traversable $namespaces) {
    $this->discovery = new AnnotatedClassDiscovery("views/{$type}", $namespaces);
    $this->discovery = new DerivativeDiscoveryDecorator($this->discovery);
    $this->discovery = new ProcessDecorator($this->discovery, array(
      $this,
      'processDefinition',
    ));
    $this->discovery = new AlterDecorator($this->discovery, 'views_plugins_' . $type);
    $this->discovery = new CacheDecorator($this->discovery, 'views:' . $type, 'views_info');
    $this->factory = new ContainerFactory($this);
    $this->defaults += array(
      'parent' => 'parent',
      'plugin_type' => $type,
      'module' => 'views',
      'register_theme' => TRUE,
    );
  }

}

Members

Namesort descending Modifiers Type Description Overrides
PluginManagerBase::$defaults protected property A set of defaults to be referenced by $this->processDefinition() if additional processing of plugins is necessary or helpful for development purposes. 3
PluginManagerBase::$discovery protected property The object that discovers plugins managed by this manager.
PluginManagerBase::$factory protected property The object that instantiates plugins managed by this manager.
PluginManagerBase::$mapper protected property The object that returns the preconfigured plugin instance appropriate for a particular runtime condition.
PluginManagerBase::clearCachedDefinitions public function Clears static and persistent plugin definition caches. Overrides CachedDiscoveryInterface::clearCachedDefinitions
PluginManagerBase::createInstance public function Returns a preconfigured instance of a plugin. Overrides FactoryInterface::createInstance 6
PluginManagerBase::getDefinition public function Gets a specific plugin definition. Overrides DiscoveryInterface::getDefinition
PluginManagerBase::getDefinitions public function Gets the definition of all plugins for this type. Overrides DiscoveryInterface::getDefinitions
PluginManagerBase::getInstance public function Returns a preconfigured instance of a plugin. Overrides MapperInterface::getInstance 6
PluginManagerBase::processDefinition public function Performs extra processing on plugin definitions. 2
ViewsPluginManager::__construct public function Constructs a ViewsPluginManager object.