function ContainerBuilder::callMethod

A 1to1 copy of parent::callMethod.

@todo https://www.drupal.org/project/drupal/issues/2937010 Since Symfony 3.4 this is not a 1to1 copy.

File

core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php, line 136

Class

ContainerBuilder
Drupal's dependency injection container builder.

Namespace

Drupal\Core\DependencyInjection

Code

protected function callMethod($service, $call, array &$inlineServices = array()) {
    $services = self::getServiceConditionals($call[1]);
    foreach ($services as $s) {
        if (!$this->has($s)) {
            return;
        }
    }
    call_user_func_array(array(
        $service,
        $call[0],
    ), $this->resolveServices($this->getParameterBag()
        ->resolveValue($call[1])));
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.