class ContainerRebuildTestServiceProvider
Same name in other branches
- 9 core/modules/system/tests/modules/container_rebuild_test/src/ContainerRebuildTestServiceProvider.php \Drupal\container_rebuild_test\ContainerRebuildTestServiceProvider
- 10 core/modules/system/tests/modules/container_rebuild_test/src/ContainerRebuildTestServiceProvider.php \Drupal\container_rebuild_test\ContainerRebuildTestServiceProvider
Hierarchy
- class \Drupal\container_rebuild_test\ContainerRebuildTestServiceProvider implements \Drupal\Core\DependencyInjection\ServiceModifierInterface
Expanded class hierarchy of ContainerRebuildTestServiceProvider
File
-
core/
modules/ system/ tests/ modules/ container_rebuild_test/ src/ ContainerRebuildTestServiceProvider.php, line 10
Namespace
Drupal\container_rebuild_testView source
class ContainerRebuildTestServiceProvider implements ServiceModifierInterface {
/**
* {@inheritdoc}
*/
public function alter(ContainerBuilder $container) {
$count = $container->get('state')
->get('container_rebuild_test.count', 0);
$container->get('state')
->set('container_rebuild_test.count', ++$count);
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title |
---|---|---|---|---|
ContainerRebuildTestServiceProvider::alter | public | function | Modifies existing service definitions. | Overrides ServiceModifierInterface::alter |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.