You are here

public function ConfigProviderServiceProvider::alter in Configuration Provider 8

Same name and namespace in other branches
  1. 8.2 src/ConfigProviderServiceProvider.php \Drupal\config_provider\ConfigProviderServiceProvider::alter()

Modifies existing service definitions.

Parameters

ContainerBuilder $container: The ContainerBuilder whose service definitions can be altered.

Overrides ServiceProviderBase::alter

File

src/ConfigProviderServiceProvider.php, line 18

Class

ConfigProviderServiceProvider
Service provider implementation for Configuration Provider.

Namespace

Drupal\config_provider

Code

public function alter(ContainerBuilder $container) {

  // Override the config.installer class with a new class.
  $definition = $container
    ->getDefinition('config.installer');
  $definition
    ->setClass('Drupal\\config_provider\\ConfigProviderConfigInstaller');
}