You are here

interface ContainerFactoryPluginInterface in Service Container 7.2

Same name and namespace in other branches
  1. 7 lib/Drupal/Core/Plugin/ContainerFactoryPluginInterface.php \Drupal\Core\Plugin\ContainerFactoryPluginInterface

Defines an interface for pulling plugin dependencies from the container.

Hierarchy

Expanded class hierarchy of ContainerFactoryPluginInterface

All classes that implement ContainerFactoryPluginInterface

2 files declare their use of ContainerFactoryPluginInterface
Plugin3A.php in modules/providers/service_container_annotation_discovery/tests/modules/service_container_annotation_discovery_test/src/Plugin/Plugin3/Plugin3A/Plugin3A.php
Plugin7A.php in modules/providers/service_container_annotation_discovery/tests/modules/service_container_annotation_discovery_subtest/src/Plugin/Plugin7/Plugin7A/Plugin7A.php

File

lib/Drupal/Core/Plugin/ContainerFactoryPluginInterface.php, line 15
Contains \Drupal\Core\Plugin\ContainerFactoryPluginInterface.

Namespace

Drupal\Core\Plugin
View source
interface ContainerFactoryPluginInterface {

  /**
   * Creates an instance of the plugin.
   *
   * @param \Symfony\Component\DependencyInjection\ContainerInterface $container
   *   The container to pull out services used in the plugin.
   * @param array $configuration
   *   A configuration array containing information about the plugin instance.
   * @param string $plugin_id
   *   The plugin ID for the plugin instance.
   * @param mixed $plugin_definition
   *   The plugin implementation definition.
   *
   * @return static
   *   Returns an instance of this plugin.
   */
  public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition);

}

Members

Namesort descending Modifiers Type Description Overrides
ContainerFactoryPluginInterface::create public static function Creates an instance of the plugin. 2