src/DependencyInjection/Compiler/GroupResolverPass.php
protected function addResolvers(ContainerBuilder $container, string $service, string $tag)
    {
        if (!$container->has($service)) {
            return;
        }

        $definition = $container->getDefinition($service);
        $taggedServices = $container->findTaggedServiceIds($tag);

        foreach ($taggedServices as $id => $tags) {
            foreach ($tags as $attributes) {
                $definition->addMethodCall('addResolver', [
                    new Reference($id)
                ]);
            }
        }
    }
protected function addResolvers(ContainerBuilder $container, string $service, string $tag)
    {
        if (!$container->has($service)) {
            return;
        }

        $definition = $container->getDefinition($service);
        $taggedServices = $container->findTaggedServiceIds($tag);

        foreach ($taggedServices as $id => $tags) {
            foreach ($tags as $attributes) {
                $definition->addMethodCall('addResolver', [
                    new Reference($id)
                ]);
            }
        }
    }
protected function addResolvers ( ContainerBuilder $ container , string $ service , string $ tag ) { if ( ! $ container -> has ( $ service ) ) { return ; } $ definition = $ container -> getDefinition ( $ service ) ; $ taggedServices = $ container -> findTaggedServiceIds ( $ tag ) ; foreach ( $ taggedServices as $ id => $ tags ) { foreach ( $ tags as $ attributes ) { $ definition -> addMethodCall ( 'addResolver' , [ new Reference ( $ id ) ] ) ; } } }
Add the Resolvers.

@param ContainerBuilder $container
@param string $service
@param string $tag

@return void
Add the Resolvers .