function OptimizedPhpArrayDumper::dumpMethodCalls
Same name in other branches
- 9 core/lib/Drupal/Component/DependencyInjection/Dumper/OptimizedPhpArrayDumper.php \Drupal\Component\DependencyInjection\Dumper\OptimizedPhpArrayDumper::dumpMethodCalls()
- 8.9.x core/lib/Drupal/Component/DependencyInjection/Dumper/OptimizedPhpArrayDumper.php \Drupal\Component\DependencyInjection\Dumper\OptimizedPhpArrayDumper::dumpMethodCalls()
- 11.x core/lib/Drupal/Component/DependencyInjection/Dumper/OptimizedPhpArrayDumper.php \Drupal\Component\DependencyInjection\Dumper\OptimizedPhpArrayDumper::dumpMethodCalls()
Dumps method calls to a PHP array.
Parameters
array $calls: An array of method calls.
Return value
array The PHP array representation of the method calls.
1 call to OptimizedPhpArrayDumper::dumpMethodCalls()
- OptimizedPhpArrayDumper::getServiceDefinition in core/
lib/ Drupal/ Component/ DependencyInjection/ Dumper/ OptimizedPhpArrayDumper.php - Gets a service definition as PHP array.
File
-
core/
lib/ Drupal/ Component/ DependencyInjection/ Dumper/ OptimizedPhpArrayDumper.php, line 276
Class
- OptimizedPhpArrayDumper
- OptimizedPhpArrayDumper dumps a service container as a serialized PHP array.
Namespace
Drupal\Component\DependencyInjection\DumperCode
protected function dumpMethodCalls(array $calls) {
$code = [];
foreach ($calls as $key => $call) {
$method = $call[0];
$arguments = [];
if (!empty($call[1])) {
$arguments = $this->dumpCollection($call[1]);
}
$code[$key] = [
$method,
$arguments,
];
}
return $code;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.