You are here

interface PluginManagerInterface in Service Container 7.2

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

Interface implemented by plugin managers.

There are no explicit methods on the manager interface. Instead plugin managers broker the interactions of the different plugin components, and therefore, must implement each component interface, which is enforced by this interface extending all of the component ones.

While a plugin manager may directly implement these interface methods with custom logic, it is expected to be more common for plugin managers to proxy the method invocations to the respective components, and directly implement only the additional functionality needed by the specific pluggable system. To follow this pattern, plugin managers can extend from the PluginManagerBase class, which contains the proxying logic.

Hierarchy

Expanded class hierarchy of PluginManagerInterface

All classes that implement PluginManagerInterface

See also

\Drupal\Component\Plugin\PluginManagerBase

7 files declare their use of PluginManagerInterface
CachedContainerBuilder.php in src/DependencyInjection/CachedContainerBuilder.php
Contains \Drupal\service_container\DependencyInjection\CachedContainerBuilder
CachedContainerBuilderTest.php in tests/src/DependencyInjection/CachedContainerBuilderTest.php
Contains \Drupal\Tests\service_container\DependencyInjection\CachedContainerBuilderTest
ContainerAwarePluginManager.php in src/Plugin/ContainerAwarePluginManager.php
Contains \Drupal\service_container\Plugin\ContainerAwarePluginManager
ContainerBuilder.php in src/DependencyInjection/ContainerBuilder.php
Contains \Drupal\service_container\DependencyInjection\ContainerBuilder
ContainerBuilderTest.php in tests/src/DependencyInjection/ContainerBuilderTest.php
Contains \Drupal\Tests\service_container\DependencyInjection\ContainerBuilderTest

... See full list

File

lib/Drupal/Component/Plugin/PluginManagerInterface.php, line 32
Contains \Drupal\Component\Plugin\PluginManagerInterface.

Namespace

Drupal\Component\Plugin
View source
interface PluginManagerInterface extends DiscoveryInterface, FactoryInterface, MapperInterface {

}

Members

Namesort descending Modifiers Type Description Overrides
DiscoveryInterface::getDefinition public function Gets a specific plugin definition. 5
DiscoveryInterface::getDefinitions public function Gets the definition of all plugins for this type. 5
DiscoveryInterface::hasDefinition public function Indicates if a specific plugin definition exists. 5
FactoryInterface::createInstance public function Creates a pre-configured instance of a plugin. 4
MapperInterface::getInstance public function Gets a preconfigured instance of a plugin. 3