From f2fef9146332f0202002c5a60a3223841d4f52d9 Mon Sep 17 00:00:00 2001 From: Diego Saint Esteben Date: Thu, 2 Jul 2015 18:05:40 -0300 Subject: [PATCH] Removed deprecated code --- .../DependencyInjection/Dumper/PhpDumper.php | 60 ------------------- 1 file changed, 60 deletions(-) diff --git a/src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php b/src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php index 6ae16ab09b..a8ac28a251 100644 --- a/src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php +++ b/src/Symfony/Component/DependencyInjection/Dumper/PhpDumper.php @@ -25,7 +25,6 @@ use Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface as use Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper; use Symfony\Component\DependencyInjection\ExpressionLanguage; use Symfony\Component\ExpressionLanguage\Expression; -use Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface; /** * PhpDumper dumps a service container as a PHP class. @@ -677,65 +676,6 @@ EOF; return $publicServices.$privateServices; } - /** - * Adds synchronizer methods. - * - * @param string $id A service identifier - * @param Definition $definition A Definition instance - * - * @return string|null - * - * @deprecated since version 2.7, will be removed in 3.0. - */ - private function addServiceSynchronizer($id, Definition $definition) - { - if (!$definition->isSynchronized(false)) { - return; - } - - if ('request' !== $id) { - @trigger_error('Synchronized services were deprecated in version 2.7 and won\'t work anymore in 3.0.', E_USER_DEPRECATED); - } - - $code = ''; - foreach ($this->container->getDefinitions() as $definitionId => $definition) { - foreach ($definition->getMethodCalls() as $call) { - foreach ($call[1] as $argument) { - if ($argument instanceof Reference && $id == (string) $argument) { - $arguments = array(); - foreach ($call[1] as $value) { - $arguments[] = $this->dumpValue($value); - } - - $call = $this->wrapServiceConditionals($call[1], sprintf("\$this->get('%s')->%s(%s);", $definitionId, $call[0], implode(', ', $arguments))); - - $code .= <<initialized('$definitionId')) { - $call - } - -EOF; - } - } - } - } - - if (!$code) { - return; - } - - return <<camelize($id)}Service() - { -$code } - -EOF; - } - private function addNewInstance($id, Definition $definition, $return, $instantiation) { $class = $this->dumpValue($definition->getClass());