private function PhpDumper::getServiceCallsFromArguments in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/symfony/dependency-injection/Dumper/PhpDumper.php \Symfony\Component\DependencyInjection\Dumper\PhpDumper::getServiceCallsFromArguments()
Builds service calls from arguments.
Parameters
array $arguments:
array &$calls By reference:
array &$behavior By reference:
1 call to PhpDumper::getServiceCallsFromArguments()
- PhpDumper::addServiceLocalTempVariables in vendor/
symfony/ dependency-injection/ Dumper/ PhpDumper.php - Generates Service local temp variables.
File
- vendor/
symfony/ dependency-injection/ Dumper/ PhpDumper.php, line 1158
Class
- PhpDumper
- PhpDumper dumps a service container as a PHP class.
Namespace
Symfony\Component\DependencyInjection\DumperCode
private function getServiceCallsFromArguments(array $arguments, array &$calls, array &$behavior) {
foreach ($arguments as $argument) {
if (is_array($argument)) {
$this
->getServiceCallsFromArguments($argument, $calls, $behavior);
}
elseif ($argument instanceof Reference) {
$id = (string) $argument;
if (!isset($calls[$id])) {
$calls[$id] = 0;
}
if (!isset($behavior[$id])) {
$behavior[$id] = $argument
->getInvalidBehavior();
}
elseif (ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $behavior[$id]) {
$behavior[$id] = $argument
->getInvalidBehavior();
}
++$calls[$id];
}
}
}