You are here

public function ServicePass::process in Devel 4.x

Same name and namespace in other branches
  1. 8.3 webprofiler/src/Compiler/ServicePass.php \Drupal\webprofiler\Compiler\ServicePass::process()
  2. 8 webprofiler/src/Compiler/ServicePass.php \Drupal\webprofiler\Compiler\ServicePass::process()
  3. 8.2 webprofiler/src/Compiler/ServicePass.php \Drupal\webprofiler\Compiler\ServicePass::process()

File

webprofiler/src/Compiler/ServicePass.php, line 18

Class

ServicePass
Class ServicePass.

Namespace

Drupal\webprofiler\Compiler

Code

public function process(ContainerBuilder $container) {
  if (FALSE === $container
    ->hasDefinition('webprofiler.services')) {
    return;
  }
  $definition = $container
    ->getDefinition('webprofiler.services');
  $graph = $container
    ->getCompiler()
    ->getServiceReferenceGraph();
  $definition
    ->addMethodCall('setServices', [
    $this
      ->extractData($container, $graph),
  ]);
}