private function PhpDumper::addServiceProperties

2 calls to PhpDumper::addServiceProperties()
PhpDumper::addService in drupal/core/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php
Adds a service
PhpDumper::addServiceInlinedDefinitions in drupal/core/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php
Generates the inline definition of a service.

File

drupal/core/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php, line 388

Class

PhpDumper
PhpDumper dumps a service container as a PHP class.

Namespace

Symfony\Component\DependencyInjection\Dumper

Code

private function addServiceProperties($id, $definition, $variableName = 'instance') {
  $code = '';
  foreach ($definition
    ->getProperties() as $name => $value) {
    $code .= sprintf("        \$%s->%s = %s;\n", $variableName, $name, $this
      ->dumpValue($value));
  }
  return $code;
}