Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ServiceProviderInterface.php

interface ServiceProviderInterface

Same name in this branch
  1. 11.1.x vendor/symfony/service-contracts/ServiceProviderInterface.php \Symfony\Contracts\Service\ServiceProviderInterface

Interface that all service providers must implement.

Hierarchy

  • interface \Drupal\Core\DependencyInjection\ServiceProviderInterface

Expanded class hierarchy of ServiceProviderInterface

All classes that implement ServiceProviderInterface

Related topics

Services and Dependency Injection Container
Overview of the Dependency Injection Container and Services.
12 files declare their use of ServiceProviderInterface
ConfigOverride.php in core/lib/Drupal/Core/Installer/ConfigOverride.php
CoreServiceProvider.php in core/lib/Drupal/Core/CoreServiceProvider.php
DrupalKernel.php in core/lib/Drupal/Core/DrupalKernel.php
InstallerServiceProvider.php in core/lib/Drupal/Core/Installer/InstallerServiceProvider.php
JsonapiServiceProvider.php in core/modules/jsonapi/src/JsonapiServiceProvider.php

... See full list

File

core/lib/Drupal/Core/DependencyInjection/ServiceProviderInterface.php, line 10

Namespace

Drupal\Core\DependencyInjection
View source
interface ServiceProviderInterface {
    
    /**
     * Registers services to the container.
     *
     * @param ContainerBuilder $container
     *   The ContainerBuilder to register services to.
     */
    public function register(ContainerBuilder $container);

}

Members

Title Sort descending Modifiers Object type Summary Overrides
ServiceProviderInterface::register public function Registers services to the container. 11
RSS feed
Powered by Drupal