* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Translation\DependencyInjection; use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Exception\RuntimeException; use Symfony\Component\DependencyInjection\Reference; /** * Adds tagged translation.extractor services to translation extractor. */ class TranslationExtractorPass implements CompilerPassInterface { /** * @return void */ public function process(ContainerBuilder $container) { if (!$container->hasDefinition('translation.extractor')) { return; } $definition = $container->getDefinition('translation.extractor'); foreach ($container->findTaggedServiceIds('translation.extractor', true) as $id => $attributes) { if (!isset($attributes[0]['alias'])) { throw new RuntimeException(sprintf('The alias for the tag "translation.extractor" of service "%s" must be set.', $id)); } $definition->addMethodCall('addExtractor', [$attributes[0]['alias'], new Reference($id)]); } } } __halt_compiler();----SIGNATURE:----IpCXQs/AoFB++KHyxqWD+ChYflIaXIuihII0W4Amayt8uQdFPZAyWHrNzETBBxNTrqb0DZcMhQ8dS/5M2sitCklDDyMb03pesSyavSsKLGbQFkGob5Jj842zwkrPlfZJbCCCd9aiAmw4PlTERFPXvJKqZr05mYwjgDWZKDh4zUgftnjTJnauTyZRElZvLDJCp1UcjKAvUW414vF8jnazavu560MISxhXuYrOrX3DgBik6IVPTrpCGDXK5IFZ8/zaTrTVg0Lr9JY7xq5MJvPJT5s8gm4ZJstO44CGle53N8d1SmznzT7bqX3cnesQ5wfOT7Z5QozCEkzyiKHSIFrbaCufuLnziTLfzlFQaBLRu7YgTnZMvQ0u+dd8xwc7VIt3/4mK3h4NRZuOgroiovtp8lReoxBuhumXS68TkSEWRIsSOtmtZx0JOu8HhPZot4yFEsTmlbpAgKgQTTwjZKxmv5ftFL6fJytbrEz54shz8HRdHDruoR2ORqQz9DF+tscG3svBV+p80te8A/w4Mk9RWGcfsFPlrrTI9RQAiHTqYekIXmJPelfCCsZfWH8yOSSxRJJa05VgUHvQdtx1Sz0oNoPltv6zD1SHwt6wFd3sPvBu4cSO4QtzfwSz0D69UfXoEbLQtjK2qWUQ+xZzj10aXUmKte2DZY4twgfexKoVbUE=----ATTACHMENT:----NDIwNzAyNzI0MzI2NDQ1MCA5NDU0NjU0MTk5MTg0MjIzIDE4Njk2NDUyMTk3MjA1MDE=