Merge branch '2.7'

* 2.7: (23 commits)
  [FrameworkBundle] Removed the use of TableHelper
  Spanish translation for the ```checkDNS``` option introduced in #12956.
  use Table instead of the deprecated TableHelper
  [2.3] fix failing test
  Fixes more deprecation notices as per @stof review.
  Fixed some deprecations according to @stof feedbacks.
  Normalizes deprecation notice messages.
  [Validator] fixes UuidValidator deprecated class namespace.
  [Form] adds more deprecation notices.
  [Validator] adds more deprecation notices.
  [Form] Adds a way to trigger deprecation notice on demand for VirtualFormAwareIterator class.
  Fixes more deprecation notices.
  Normalized @deprecated annotations.
  Removed deprecation notices from test files.
  Fixes deprecation notices.
  Reverted trigger_error() function calls on deprecated interfaces to prevent breaking third party projects implementing them.
  Adds deprecation notices for structures to be removed in 3.0.
  fixed typo
  Escape annotations in comments, refs #13089.
  [2.3] missing cleanup for legacy test
  ...

Conflicts:
	.travis.yml
	src/Symfony/Bridge/Monolog/Logger.php
	src/Symfony/Bridge/Swiftmailer/DataCollector/MessageDataCollector.php
	src/Symfony/Bridge/Twig/Node/FormEnctypeNode.php
	src/Symfony/Bundle/FrameworkBundle/Command/RouterApacheDumperCommand.php
	src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/Descriptor.php
	src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/TextDescriptor.php
	src/Symfony/Bundle/FrameworkBundle/Controller/Controller.php
	src/Symfony/Bundle/FrameworkBundle/HttpCache/HttpCache.php
	src/Symfony/Bundle/FrameworkBundle/Templating/Helper/FormHelper.php
	src/Symfony/Bundle/FrameworkBundle/Tests/Fixtures/Descriptor/builder_1_public.txt
	src/Symfony/Bundle/FrameworkBundle/Tests/Fixtures/Descriptor/builder_1_services.txt
	src/Symfony/Bundle/FrameworkBundle/Tests/Fixtures/Descriptor/builder_1_tag1.txt
	src/Symfony/Bundle/FrameworkBundle/Tests/Fixtures/Descriptor/parameters_1.txt
	src/Symfony/Bundle/FrameworkBundle/Tests/Fixtures/Descriptor/route_collection_1.txt
	src/Symfony/Bundle/FrameworkBundle/composer.json
	src/Symfony/Component/Config/Definition/ReferenceDumper.php
	src/Symfony/Component/Console/Helper/DialogHelper.php
	src/Symfony/Component/Console/Helper/ProgressHelper.php
	src/Symfony/Component/Console/Helper/TableHelper.php
	src/Symfony/Component/Form/Deprecated/FormEvents.php
	src/Symfony/Component/Form/Extension/HttpFoundation/EventListener/BindRequestListener.php
	src/Symfony/Component/Form/FormEvents.php
	src/Symfony/Component/HttpKernel/Debug/ErrorHandler.php
	src/Symfony/Component/HttpKernel/Debug/ExceptionHandler.php
	src/Symfony/Component/HttpKernel/Kernel.php
	src/Symfony/Component/HttpKernel/KernelInterface.php
	src/Symfony/Component/OptionsResolver/Tests/LegacyOptionsTest.php
	src/Symfony/Component/Process/Process.php
	src/Symfony/Component/Routing/Matcher/ApacheUrlMatcher.php
	src/Symfony/Component/Routing/Matcher/Dumper/ApacheMatcherDumper.php
	src/Symfony/Component/Yaml/Yaml.php
This commit is contained in:
Fabien Potencier 2015-01-06 11:39:25 +01:00
commit 481a0149cb
172 changed files with 874 additions and 474 deletions

View File

@ -3,11 +3,11 @@ language: php
matrix:
include:
- php: 5.5.9
- php: 5.5
- php: 5.6
env: components=low
- php: 5.6
env: components=high
- php: 5.5
- php: 5.6
- php: hhvm-nightly
allow_failures:
- php: hhvm-nightly
@ -29,13 +29,14 @@ before_install:
- if [ "$TRAVIS_PHP_VERSION" != "hhvm-nightly" ]; then echo "extension = memcache.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi;
- if [ "$TRAVIS_PHP_VERSION" != "hhvm-nightly" ]; then php -i; fi;
- sudo locale-gen fr_FR.UTF-8 && sudo update-locale
# - if [ "$TRAVIS_PHP_VERSION" != "5.3.3" ]; then phpunit --self-update; fi;
# Set the COMPOSER_ROOT_VERSION to the right version according to the branch being built
- if [ "$TRAVIS_BRANCH" = "master" ]; then export COMPOSER_ROOT_VERSION=dev-master; else export COMPOSER_ROOT_VERSION="$TRAVIS_BRANCH".x-dev; fi;
install:
- if [ "$components" = "no" ]; then COMPOSER_ROOT_VERSION=dev-master composer --prefer-source --dev install; fi;
- if [ "$components" = "no" ]; then composer --prefer-source --dev install; fi;
script:
- if [ "$components" = "no" ]; then ls -d src/Symfony/*/* | parallel --gnu --keep-order 'echo -e "\\nRunning {} tests"; phpunit --exclude-group tty,benchmark,intl-data {} || (echo -e "\\e[41mKO\\e[0m {}" && $(exit 1));'; fi;
- if [ "$components" = "no" ]; then echo -e "\\nRunning tests requiring tty"; phpunit --group tty || (echo -e "\\e[41mKO\\e[0m tty group" && $(exit 1)); fi;
- if [ "$components" = "high" ]; then find src/Symfony -mindepth 3 -type f -name phpunit.xml.dist | sed 's#\(.*\)/.*#\1#' | parallel --gnu --keep-order -j25% 'echo -e "\\nRunning {} tests"; cd {}; COMPOSER_ROOT_VERSION=dev-master composer --prefer-source --dev update; phpunit --exclude-group tty,benchmark,intl-data || (echo -e "\\e[41mKO\\e[0m {}" && $(exit 1));'; fi;
- if [ "$components" = "low" ]; then find src/Symfony -mindepth 3 -type f -name phpunit.xml.dist | sed 's#\(.*\)/.*#\1#' | parallel --gnu --keep-order -j25% 'echo -e "\\nRunning {} tests"; cd {}; COMPOSER_ROOT_VERSION=dev-master composer --prefer-source --dev --prefer-lowest --prefer-stable update; phpunit --exclude-group tty,benchmark,intl-data || (echo -e "\\e[41mKO\\e[0m {}" && $(exit 1));'; fi;
- if [ "$components" = "high" ]; then find src/Symfony -mindepth 3 -type f -name phpunit.xml.dist | sed 's#\(.*\)/.*#\1#' | parallel --gnu --keep-order -j25% 'echo -e "\\nRunning {} tests"; cd {}; composer --prefer-source --dev update; phpunit --exclude-group tty,benchmark,intl-data || (echo -e "\\e[41mKO\\e[0m {}" && $(exit 1));'; fi;
- if [ "$components" = "low" ]; then find src/Symfony -mindepth 3 -type f -name phpunit.xml.dist | sed 's#\(.*\)/.*#\1#' | parallel --gnu --keep-order -j25% 'echo -e "\\nRunning {} tests"; cd {}; composer --prefer-source --dev --prefer-lowest --prefer-stable update; phpunit --exclude-group tty,benchmark,intl-data || (echo -e "\\e[41mKO\\e[0m {}" && $(exit 1));'; fi;

View File

@ -1,6 +1,13 @@
UPGRADE FROM 2.4 to 2.5
=======================
FrameworkBundle
---------------
* The `Symfony\Bundle\FrameworkBundle\Console\Descriptor\Descriptor::renderTable()`
method expects the table to be an instance of `Symfony\Component\Console\Helper\Table`
instead of `Symfony\Component\Console\Helper\TableHelper`.
Routing
-------

View File

@ -1,6 +1,11 @@
CHANGELOG
=========
2.4.0
-----
* deprecated DoctrineOrmTestCase class
2.2.0
-----

View File

@ -296,10 +296,12 @@ class EntityChoiceList extends ObjectChoiceList
*
* @see ChoiceListInterface
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForChoices(array $entities)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
// Performance optimization
if (empty($entities)) {
return array();
@ -338,10 +340,12 @@ class EntityChoiceList extends ObjectChoiceList
*
* @see ChoiceListInterface
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForValues(array $values)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
// Performance optimization
if (empty($values)) {
return array();

View File

@ -11,18 +11,21 @@
namespace Symfony\Bridge\Doctrine\Tests;
trigger_error('The '.__NAMESPACE__.'\DoctrineOrmTestCase class is deprecated since version 2.4 and will be removed in 3.0. Use Symfony\Bridge\Doctrine\Test\DoctrineTestHelper class instead.', E_USER_DEPRECATED);
use Doctrine\ORM\EntityManager;
use Symfony\Bridge\Doctrine\Test\DoctrineTestHelper;
/**
* Class DoctrineOrmTestCase.
*
* @deprecated Deprecated as of Symfony 2.3, to be removed in Symfony 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
* Use {@link DoctrineTestHelper} instead.
*/
abstract class DoctrineOrmTestCase extends \PHPUnit_Framework_TestCase
{
/**
* @return \Doctrine\ORM\EntityManager
* @return EntityManager
*/
public static function createTestEntityManager()
{

View File

@ -24,41 +24,41 @@ class Logger extends BaseLogger implements LoggerInterface, DebugLoggerInterface
{
/**
* @see Symfony\Component\HttpKernel\Log\DebugLoggerInterface
* @deprecated since 2.2, to be removed in 3.0. Use emergency() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use emergency() which is PSR-3 compatible.
*/
public function emerg($message, array $context = array())
{
trigger_error('The emerg() method of the Monolog Logger was removed. You should use the new method emergency() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method inherited from the Symfony\Component\HttpKernel\Log\LoggerInterface interface is deprecated since version 2.2 and will be removed in 3.0. Use the emergency() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
return parent::addRecord(BaseLogger::EMERGENCY, $message, $context);
}
/**
* @deprecated since 2.2, to be removed in 3.0. Use critical() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use critical() which is PSR-3 compatible.
*/
public function crit($message, array $context = array())
{
trigger_error('The crit() method of the Monolog Logger was removed. You should use the new method critical() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method inherited from the Symfony\Component\HttpKernel\Log\LoggerInterface interface is deprecated since version 2.2 and will be removed in 3.0. Use the method critical() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
return parent::addRecord(BaseLogger::CRITICAL, $message, $context);
}
/**
* @deprecated since 2.2, to be removed in 3.0. Use error() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use error() which is PSR-3 compatible.
*/
public function err($message, array $context = array())
{
trigger_error('The err() method of the Monolog Logger was removed. You should use the new method error() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method inherited from the Symfony\Component\HttpKernel\Log\LoggerInterface interface is deprecated since version 2.2 and will be removed in 3.0. Use the error() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
return parent::addRecord(BaseLogger::ERROR, $message, $context);
}
/**
* @deprecated since 2.2, to be removed in 3.0. Use warning() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use warning() which is PSR-3 compatible.
*/
public function warn($message, array $context = array())
{
trigger_error('The warn() method of the Monolog Logger was removed. You should use the new method warning() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method inherited from the Symfony\Component\HttpKernel\Log\LoggerInterface interface is deprecated since version 2.2 and will be removed in 3.0. Use the warning() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
return parent::addRecord(BaseLogger::WARNING, $message, $context);
}

View File

@ -300,10 +300,12 @@ class ModelChoiceList extends ObjectChoiceList
/**
* {@inheritdoc}
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForChoices(array $models)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
if (empty($models)) {
return array();
}
@ -319,7 +321,7 @@ class ModelChoiceList extends ObjectChoiceList
* but if they originated from different queries, there are not the same object within the code.
*
* This happens when using m:n relations with either sides model as data_class of the form.
* The choicelist will retrieve the list of available related models with a different query, resulting in different objects.
* The choice list will retrieve the list of available related models with a different query, resulting in different objects.
*/
$choices = $this->fixChoices($models);
foreach ($choices as $i => $givenChoice) {
@ -346,10 +348,12 @@ class ModelChoiceList extends ObjectChoiceList
/**
* {@inheritdoc}
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForValues(array $values)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
if (empty($values)) {
return array();
}

View File

@ -12,6 +12,7 @@
namespace Symfony\Bundle\FrameworkBundle\Console\Descriptor;
use Symfony\Component\Console\Descriptor\DescriptorInterface;
use Symfony\Component\Console\Helper\Table;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\DependencyInjection\Alias;
use Symfony\Component\DependencyInjection\ContainerBuilder;
@ -77,6 +78,16 @@ abstract class Descriptor implements DescriptorInterface
}
}
/**
* Returns the output.
*
* @return OutputInterface The output
*/
protected function getOutput()
{
return $this->output;
}
/**
* Writes content to output.
*

View File

@ -30,10 +30,10 @@ class TextDescriptor extends Descriptor
*/
protected function describeRouteCollection(RouteCollection $routes, array $options = array())
{
$table = new Table($this->output);
$showControllers = isset($options['show_controllers']) && $options['show_controllers'];
$headers = array('Name', 'Method', 'Scheme', 'Host', 'Path');
$table = new Table($this->output);
$table->setHeaders($showControllers ? array_merge($headers, array('Controller')) : $headers);
foreach ($routes->all() as $name => $route) {
@ -322,6 +322,7 @@ class TextDescriptor extends Descriptor
foreach ($eventListeners as $order => $eventListener) {
$table->addRow(array(sprintf('#%d', $order + 1), $this->formatCallable($eventListener)));
}
$table->render();
}
}

View File

@ -116,7 +116,7 @@ class Configuration implements ConfigurationInterface
->children()
->scalarNode('field_name')
->defaultValue('_token')
->info('Deprecated since 2.4, to be removed in 3.0. Use form.csrf_protection.field_name instead')
->info('Deprecated since version 2.4, to be removed in 3.0. Use form.csrf_protection.field_name instead')
->end()
->end()
->end()

View File

@ -11,6 +11,8 @@
namespace Symfony\Bundle\FrameworkBundle\Templating;
trigger_error('The '.__NAMESPACE__.'\Debugger class is deprecated since version 2.4 and will be removed in 3.0. Use the Psr\Log\LoggerInterface interface instead.', E_USER_DEPRECATED);
use Symfony\Component\Templating\DebuggerInterface;
use Psr\Log\LoggerInterface;
@ -19,7 +21,8 @@ use Psr\Log\LoggerInterface;
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated Deprecated in 2.4, to be removed in 3.0. Use Psr\Log\LoggerInterface instead.
* @deprecated since version 2.4, to be removed in 3.0.
* Use Psr\Log\LoggerInterface instead.
*/
class Debugger implements DebuggerInterface
{

View File

@ -37,11 +37,14 @@ class GlobalVariables
/**
* Returns the security context service.
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*
* @return SecurityContext|null The security context
*/
public function getSecurity()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0.', E_USER_DEPRECATED);
if ($this->container->has('security.context')) {
return $this->container->get('security.context');
}

View File

@ -30,11 +30,12 @@ class RequestHelper extends Helper
*
* @param Request|RequestStack $requestStack A RequestStack instance or a Request instance
*
* @deprecated since 2.5, passing a Request instance is deprecated and support for it will be removed in 3.0
* @deprecated since version 2.5, passing a Request instance is deprecated and support for it will be removed in 3.0.
*/
public function __construct($requestStack)
{
if ($requestStack instanceof Request) {
trigger_error('Since version 2.5, passing a Request instance into the '.__METHOD__.' is deprecated and support for it will be removed in 3.0. Inject a Symfony\Component\HttpFoundation\RequestStack instance instead.', E_USER_DEPRECATED);
$this->request = $requestStack;
} elseif ($requestStack instanceof RequestStack) {
$this->requestStack = $requestStack;

View File

@ -30,11 +30,12 @@ class SessionHelper extends Helper
*
* @param Request|RequestStack $requestStack A RequestStack instance or a Request instance
*
* @deprecated since 2.5, passing a Request instance is deprecated and support for it will be removed in 3.0
* @deprecated since version 2.5, passing a Request instance is deprecated and support for it will be removed in 3.0.
*/
public function __construct($requestStack)
{
if ($requestStack instanceof Request) {
trigger_error('Since version 2.5, passing a Request instance into the '.__METHOD__.' is deprecated and support for it will be removed in 3.0. Inject a Symfony\Component\HttpFoundation\RequestStack instance instead.', E_USER_DEPRECATED);
$this->session = $requestStack->getSession();
} elseif ($requestStack instanceof RequestStack) {
$this->requestStack = $requestStack;

View File

@ -32,19 +32,19 @@
"doctrine/annotations": "~1.0"
},
"require-dev": {
"symfony/browser-kit": "~2.7|~3.0",
"symfony/console": "~2.7|~3.0",
"symfony/css-selector": "~2.7|~3.0",
"symfony/dom-crawler": "~2.7|~3.0",
"symfony/finder": "~2.7|~3.0",
"symfony/intl": "~2.7|~3.0",
"symfony/security": "~2.7|~3.0",
"symfony/form": "~2.7|~3.0",
"symfony/class-loader": "~2.7|~3.0",
"symfony/expression-language": "~2.7|~3.0",
"symfony/process": "~2.7|~3.0",
"symfony/validator": "~2.7|~3.0",
"symfony/yaml": "~2.7|~3.0"
"symfony/browser-kit": "~2.4|~3.0.0",
"symfony/console": "~2.6|~3.0.0",
"symfony/css-selector": "~2.0,>=2.0.5|~3.0.0",
"symfony/dom-crawler": "~2.0,>=2.0.5|~3.0.0",
"symfony/finder": "~2.0,>=2.0.5|~3.0.0",
"symfony/intl": "~2.3|~3.0.0",
"symfony/security": "~2.6|~3.0.0",
"symfony/form": "~2.6|~3.0.0",
"symfony/class-loader": "~2.1|~3.0.0",
"symfony/expression-language": "~2.6|~3.0.0",
"symfony/process": "~2.0,>=2.0.5|~3.0.0",
"symfony/validator": "~2.5|~3.0.0",
"symfony/yaml": "~2.0,>=2.0.5|~3.0.0"
},
"suggest": {
"symfony/console": "For using the console commands",

View File

@ -61,7 +61,7 @@ class Configuration implements ConfigurationInterface
->end()
->children()
->arrayNode('form')
->info('Deprecated since 2.6, to be removed in 3.0. Use twig.form_themes instead')
->info('Deprecated since version 2.6, to be removed in 3.0. Use twig.form_themes instead')
->addDefaultsIfNotSet()
->fixXmlConfig('resource')
->children()

View File

@ -20,7 +20,7 @@ use Symfony\Component\HttpKernel\Fragment\FragmentHandler;
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated Deprecated in 2.2, to be removed in 3.0.
* @deprecated since version 2.2, to be removed in 3.0.
*/
class ActionsExtension extends \Twig_Extension
{
@ -29,14 +29,14 @@ class ActionsExtension extends \Twig_Extension
/**
* @param FragmentHandler|ContainerInterface $handler
*
* @deprecated Passing a ContainerInterface as a first argument is deprecated as of 2.7 and will be removed in 3.0.
* @deprecated Passing a ContainerInterface as a first argument is deprecated since 2.7 and will be removed in 3.0.
*/
public function __construct($handler)
{
if ($handler instanceof FragmentHandler) {
$this->handler = $handler;
} elseif ($handler instanceof ContainerInterface) {
trigger_error(sprintf('The ability to pass a ContainerInterface instance as a first argument to %s was deprecated in 2.7 and will be removed in 3.0. Please, pass a FragmentHandler instance instead.', __METHOD__), E_USER_DEPRECATED);
trigger_error('The ability to pass a ContainerInterface instance as a first argument to '.__METHOD__.' method is deprecated since version 2.7 and will be removed in 3.0. Pass a FragmentHandler instance instead.', E_USER_DEPRECATED);
$this->handler = $handler->get('fragment.handler');
} else {

View File

@ -9,7 +9,7 @@
<xsd:complexType name="config">
<xsd:sequence>
<!-- @deprecated since 2.6, to be removed in 3.0 -->
<!-- @deprecated since version 2.6, to be removed in 3.0 -->
<xsd:element name="form" type="form" minOccurs="0" maxOccurs="1" />
<xsd:element name="form-theme" type="xsd:string" minOccurs="0" maxOccurs="unbounded" />
<xsd:element name="global" type="global" minOccurs="0" maxOccurs="unbounded" />

View File

@ -57,7 +57,7 @@ class TwigExtensionTest extends TestCase
$resources = $container->getParameter('twig.form.resources');
$this->assertContains('form_div_layout.html.twig', $resources, '->load() includes default template for form resources');
$this->assertContains('MyBundle::form.html.twig', $resources, '->load() merges new templates into form resources');
// @deprecated since 2.6, to be removed in 3.0
// @deprecated since version 2.6, to be removed in 3.0
$this->assertContains('MyBundle::formDeprecated.html.twig', $resources, '->load() merges new templates into form resources');
// Globals

View File

@ -42,19 +42,24 @@ class TwigEngine extends BaseEngine implements EngineInterface
}
/**
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Inject the escaping
* strategy on Twig_Environment instead
* @deprecated since version 2.7, to be removed in 3.0.
* Inject the escaping strategy on \Twig_Environment instead.
*/
public function setDefaultEscapingStrategy($strategy)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.7 and will be removed in 3.0. Inject the escaping strategy in the Twig_Environment object instead.', E_USER_DEPRECATED);
$this->environment->getExtension('escaper')->setDefaultStrategy($strategy);
}
/**
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use TwigDefaultEscapingStrategy instead.
* @deprecated since version 2.7, to be removed in 3.0.
* Use TwigDefaultEscapingStrategy instead.
*/
public function guessDefaultEscapingStrategy($filename)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.7 and will be removed in 3.0. Use the Symfony\Bundle\TwigBundle\TwigDefaultEscapingStrategy::guess method instead.', E_USER_DEPRECATED);
return TwigDefaultEscapingStrategy::guess($filename);
}

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\ClassLoader;
trigger_error('The '.__NAMESPACE__.'\ApcUniversalClassLoader class is deprecated since version 2.7 and will be removed in 3.0. Use the Symfony\Component\ClassLoader\ApcClassLoader class instead.', E_USER_DEPRECATED);
/**
* ApcUniversalClassLoader implements a "universal" autoloader cached in APC for PHP 5.3.
*
@ -60,7 +62,8 @@ namespace Symfony\Component\ClassLoader;
*
* @api
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0. Use the ApcClassLoader class instead.
* @deprecated since version 2.4, to be removed in 3.0.
* Use the {@link ClassLoader} class instead.
*/
class ApcUniversalClassLoader extends UniversalClassLoader
{

View File

@ -1,11 +1,6 @@
CHANGELOG
=========
2.7.0
-----
* The UniversalClassLoader class has been deprecated in favor of ClassLoader class
2.4.0
-----

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\ClassLoader;
trigger_error('The '.__NAMESPACE__.'\DebugClassLoader class is deprecated since version 2.4 and will be removed in 3.0. Use the Symfony\Component\Debug\DebugClassLoader class instead.', E_USER_DEPRECATED);
/**
* Autoloader checking if the class is really defined in the file found.
*
@ -23,7 +25,8 @@ namespace Symfony\Component\ClassLoader;
*
* @api
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0. Use the DebugClassLoader provided by the Debug component instead.
* @deprecated since version 2.4, to be removed in 3.0.
* Use {@link \Symfony\Component\Debug\DebugClassLoader} instead.
*/
class DebugClassLoader
{

View File

@ -11,12 +11,15 @@
namespace Symfony\Component\ClassLoader;
trigger_error('The '.__NAMESPACE__.'\DebugUniversalClassLoader class is deprecated since version 2.4 and will be removed in 3.0. Use the Symfony\Component\Debug\DebugClassLoader class instead.', E_USER_DEPRECATED);
/**
* Checks that the class is actually declared in the included file.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0. Use the DebugClassLoader provided by the Debug component instead.
* @deprecated since version 2.4, to be removed in 3.0.
* Use the {@link \Symfony\Component\Debug\DebugClassLoader} class instead.
*/
class DebugUniversalClassLoader extends UniversalClassLoader
{

View File

@ -11,7 +11,7 @@
namespace Symfony\Component\ClassLoader;
trigger_error('The "Symfony\Component\ClassLoader\UniversalClassLoader" class was deprecated in version 2.7 and will be removed in 3.0. Use "Symfony\Component\ClassLoader\ClassLoader" instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\UniversalClassLoader class is deprecated since version 2.7 and will be removed in 3.0. Use the Symfony\Component\ClassLoader\ClassLoader class instead.', E_USER_DEPRECATED);
/**
* UniversalClassLoader implements a "universal" autoloader for PHP 5.3.
@ -60,7 +60,8 @@ trigger_error('The "Symfony\Component\ClassLoader\UniversalClassLoader" class wa
*
* @api
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0. Use the ClassLoader class instead.
* @deprecated since version 2.4, to be removed in 3.0.
* Use the {@link ClassLoader} class instead.
*/
class UniversalClassLoader
{

View File

@ -621,10 +621,12 @@ class Application
*
* @return string A string representing the Application
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0.
* @deprecated since version 2.3, to be removed in 3.0.
*/
public function asText($namespace = null, $raw = false)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0.', E_USER_DEPRECATED);
$descriptor = new TextDescriptor();
$output = new BufferedOutput(BufferedOutput::VERBOSITY_NORMAL, !$raw);
$descriptor->describe($output, $this, array('namespace' => $namespace, 'raw_output' => true));
@ -640,10 +642,12 @@ class Application
*
* @return string|\DOMDocument An XML string representing the Application
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0.
* @deprecated since version 2.3, to be removed in 3.0.
*/
public function asXml($namespace = null, $asDom = false)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0.', E_USER_DEPRECATED);
$descriptor = new XmlDescriptor();
if ($asDom) {

View File

@ -605,10 +605,12 @@ class Command
*
* @return string A string representing the command
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0.
* @deprecated since version 2.3, to be removed in 3.0.
*/
public function asText()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0.', E_USER_DEPRECATED);
$descriptor = new TextDescriptor();
$output = new BufferedOutput(BufferedOutput::VERBOSITY_NORMAL, true);
$descriptor->describe($output, $this, array('raw_output' => true));
@ -623,10 +625,12 @@ class Command
*
* @return string|\DOMDocument An XML string representing the command
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0.
* @deprecated since version 2.3, to be removed in 3.0.
*/
public function asXml($asDom = false)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0.', E_USER_DEPRECATED);
$descriptor = new XmlDescriptor();
if ($asDom) {

View File

@ -171,12 +171,14 @@ class ProgressBar
/**
* Gets the progress bar step.
*
* @deprecated since 2.6, to be removed in 3.0. Use {@link getProgress()} instead.
* @deprecated since version 2.6, to be removed in 3.0. Use {@link getProgress()} instead.
*
* @return int The progress bar step
*/
public function getStep()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the getProgress() method instead.', E_USER_DEPRECATED);
return $this->getProgress();
}
@ -356,7 +358,7 @@ class ProgressBar
/**
* Sets the current progress.
*
* @deprecated since 2.6, to be removed in 3.0. Use {@link setProgress()} instead.
* @deprecated since version 2.6, to be removed in 3.0. Use {@link setProgress()} instead.
*
* @param int $step The current progress
*
@ -364,6 +366,8 @@ class ProgressBar
*/
public function setCurrent($step)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the setProgress() method instead.', E_USER_DEPRECATED);
$this->setProgress($step);
}

View File

@ -417,10 +417,12 @@ class InputDefinition
*
* @return string A string representing the InputDefinition
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0.
* @deprecated since version 2.3, to be removed in 3.0.
*/
public function asText()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0.', E_USER_DEPRECATED);
$descriptor = new TextDescriptor();
$output = new BufferedOutput(BufferedOutput::VERBOSITY_NORMAL, true);
$descriptor->describe($output, $this, array('raw_output' => true));
@ -435,10 +437,12 @@ class InputDefinition
*
* @return string|\DOMDocument An XML string representing the InputDefinition
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0.
* @deprecated since version 2.3, to be removed in 3.0.
*/
public function asXml($asDom = false)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0.', E_USER_DEPRECATED);
$descriptor = new XmlDescriptor();
if ($asDom) {

View File

@ -39,6 +39,10 @@ class StringInput extends ArgvInput
*/
public function __construct($input, InputDefinition $definition = null)
{
if ($definition) {
trigger_error('The $definition argument of the '.__METHOD__.' method is deprecated and will be removed in 3.0. Set this parameter with the bind() method instead.', E_USER_DEPRECATED);
}
parent::__construct(array(), null);
$this->setTokens($this->tokenize($input));

View File

@ -35,16 +35,16 @@ class DebugClassLoader
/**
* Constructor.
*
* @param callable|object $classLoader
* @param callable|object $classLoader Passing an object is @deprecated since version 2.5 and support for it will be removed in 3.0
*
* @api
* @deprecated since 2.5, passing an object is deprecated and support for it will be removed in 3.0
*/
public function __construct($classLoader)
{
$this->wasFinder = is_object($classLoader) && method_exists($classLoader, 'findFile');
if ($this->wasFinder) {
trigger_error('The '.__METHOD__.' method will no longer support receiving an object into its $classLoader argument in 3.0.', E_USER_DEPRECATED);
$this->classLoader = array($classLoader, 'loadClass');
$this->isFinder = true;
} else {
@ -60,9 +60,7 @@ class DebugClassLoader
/**
* Gets the wrapped class loader.
*
* @return callable|object a class loader
*
* @deprecated since 2.5, returning an object is deprecated and support for it will be removed in 3.0
* @return callable|object A class loader. Since version 2.5, returning an object is @deprecated and support for it will be removed in 3.0
*/
public function getClassLoader()
{
@ -124,10 +122,12 @@ class DebugClassLoader
*
* @return string|null
*
* @deprecated Deprecated since 2.5, to be removed in 3.0.
* @deprecated since version 2.5, to be removed in 3.0.
*/
public function findFile($class)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.5 and will be removed in 3.0.', E_USER_DEPRECATED);
if ($this->wasFinder) {
return $this->classLoader[0]->findFile($class);
}

View File

@ -46,7 +46,7 @@ use Symfony\Component\Debug\FatalErrorHandler\FatalErrorHandlerInterface;
class ErrorHandler
{
/**
* @deprecated since 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
const TYPE_DEPRECATION = -100;
@ -103,14 +103,14 @@ class ErrorHandler
/**
* Same init value as thrownErrors
*
* @deprecated since 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
private $displayErrors = 0x1FFF;
/**
* Registers the error handler.
*
* @param self|null|int $handler The handler to register, or @deprecated (since 2.6, to be removed in 3.0) bit field of thrown levels
* @param self|null|int $handler The handler to register, or @deprecated (since version 2.6, to be removed in 3.0) bit field of thrown levels
* @param bool $replace Whether to replace or not any existing handler
*
* @return self The registered error handler
@ -256,7 +256,7 @@ class ErrorHandler
}
$this->reRegister($prev | $this->loggedErrors);
// $this->displayErrors is @deprecated since 2.6
// $this->displayErrors is @deprecated since version 2.6
$this->displayErrors = $this->thrownErrors;
return $prev;
@ -572,10 +572,12 @@ class ErrorHandler
*
* @param int|null $level The level (null to use the error_reporting() value and 0 to disable)
*
* @deprecated since 2.6, to be removed in 3.0. Use throwAt() instead.
* @deprecated since version 2.6, to be removed in 3.0. Use throwAt() instead.
*/
public function setLevel($level)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the throwAt() method instead.', E_USER_DEPRECATED);
$level = null === $level ? error_reporting() : $level;
$this->throwAt($level, true);
}
@ -585,10 +587,12 @@ class ErrorHandler
*
* @param int $displayErrors The display_errors flag value
*
* @deprecated since 2.6, to be removed in 3.0. Use throwAt() instead.
* @deprecated since version 2.6, to be removed in 3.0. Use throwAt() instead.
*/
public function setDisplayErrors($displayErrors)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the throwAt() method instead.', E_USER_DEPRECATED);
if ($displayErrors) {
$this->throwAt($this->displayErrors, true);
} else {
@ -604,10 +608,12 @@ class ErrorHandler
* @param LoggerInterface $logger A logger interface
* @param string $channel The channel associated with the logger (deprecation, emergency or scream)
*
* @deprecated since 2.6, to be removed in 3.0. Use setLoggers() or setDefaultLogger() instead.
* @deprecated since version 2.6, to be removed in 3.0. Use setLoggers() or setDefaultLogger() instead.
*/
public static function setLogger(LoggerInterface $logger, $channel = 'deprecation')
{
trigger_error('The '.__METHOD__.' static method is deprecated since version 2.6 and will be removed in 3.0. Use the setLoggers() or setDefaultLogger() methods instead.', E_USER_DEPRECATED);
$handler = set_error_handler('var_dump', 0);
$handler = is_array($handler) ? $handler[0] : null;
restore_error_handler();
@ -627,20 +633,24 @@ class ErrorHandler
}
/**
* @deprecated since 2.6, to be removed in 3.0. Use handleError() instead.
* @deprecated since version 2.6, to be removed in 3.0. Use handleError() instead.
*/
public function handle($level, $message, $file = 'unknown', $line = 0, $context = array())
{
$this->handleError(E_USER_DEPRECATED, 'The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the handleError() method instead.', __FILE__, __LINE__, array());
return $this->handleError($level, $message, $file, $line, (array) $context);
}
/**
* Handles PHP fatal errors.
*
* @deprecated since 2.6, to be removed in 3.0. Use handleFatalError() instead.
* @deprecated since version 2.6, to be removed in 3.0. Use handleFatalError() instead.
*/
public function handleFatal()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the handleFatalError() method instead.', E_USER_DEPRECATED);
static::handleFatalError();
}
}

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Debug\Exception;
trigger_error('The '.__NAMESPACE__.'\DummyException class is deprecated since version 2.5 and will be removed in 3.0.', E_USER_DEPRECATED);
/**
* @author Fabien Potencier <fabien@symfony.com>
*

View File

@ -101,7 +101,7 @@ class ClassNotFoundFatalErrorHandler implements FatalErrorHandlerInterface
if ($function[0] instanceof DebugClassLoader) {
$function = $function[0]->getClassLoader();
// Since 2.5, returning an object from DebugClassLoader::getClassLoader() is @deprecated
// @deprecated since version 2.5. Returning an object from DebugClassLoader::getClassLoader() is deprecated.
if (is_object($function)) {
$function = array($function);
}

View File

@ -380,7 +380,7 @@ class ErrorHandlerTest extends \PHPUnit_Framework_TestCase
;
$handler = ErrorHandler::register(E_NOTICE);
$handler->setLogger($logger, 'scream');
@$handler->setLogger($logger, 'scream');
unset($undefVar);
@$undefVar++;

View File

@ -94,11 +94,11 @@ class Definition
* @return Definition The current instance
*
* @api
* @deprecated Deprecated since version 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
public function setFactoryClass($factoryClass)
{
trigger_error('Definition::setFactoryClass() is deprecated since version 2.6 and will be removed in 3.0. Use Definition::setFactory() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' is deprecated since version 2.6 and will be removed in 3.0. Use Definition::setFactory() instead.', E_USER_DEPRECATED);
$this->factoryClass = $factoryClass;
@ -111,10 +111,12 @@ class Definition
* @return string|null The factory class name
*
* @api
* @deprecated Deprecated since version 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
public function getFactoryClass()
{
trigger_error('The '.__METHOD__.' is deprecated since version 2.6 and will be removed in 3.0.', E_USER_DEPRECATED);
return $this->factoryClass;
}
@ -126,11 +128,11 @@ class Definition
* @return Definition The current instance
*
* @api
* @deprecated Deprecated since version 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
public function setFactoryMethod($factoryMethod)
{
trigger_error('Definition::setFactoryMethod() is deprecated since version 2.6 and will be removed in 3.0. Use Definition::setFactory() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' is deprecated since version 2.6 and will be removed in 3.0. Use Definition::setFactory() instead.', E_USER_DEPRECATED);
$this->factoryMethod = $factoryMethod;
@ -178,10 +180,12 @@ class Definition
* @return string|null The factory method name
*
* @api
* @deprecated Deprecated since version 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
public function getFactoryMethod()
{
trigger_error('The '.__METHOD__.' is deprecated since version 2.6 and will be removed in 3.0.', E_USER_DEPRECATED);
return $this->factoryMethod;
}
@ -193,11 +197,11 @@ class Definition
* @return Definition The current instance
*
* @api
* @deprecated Deprecated since version 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
public function setFactoryService($factoryService)
{
trigger_error('Definition::setFactoryService() is deprecated since version 2.6 and will be removed in 3.0. Use Definition::setFactory() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' is deprecated since version 2.6 and will be removed in 3.0. Use Definition::setFactory() instead.', E_USER_DEPRECATED);
$this->factoryService = $factoryService;
@ -210,10 +214,12 @@ class Definition
* @return string|null The factory service id
*
* @api
* @deprecated Deprecated since version 2.6, to be removed in 3.0.
* @deprecated since version 2.6, to be removed in 3.0.
*/
public function getFactoryService()
{
trigger_error('The '.__METHOD__.' is deprecated since version 2.6 and will be removed in 3.0.', E_USER_DEPRECATED);
return $this->factoryService;
}

View File

@ -1401,12 +1401,15 @@ EOF;
}
/**
* @deprecated Deprecated since 2.6.2, to be removed in 3.0. Use Symfony\Component\DependencyInjection\ContainerBuilder::addExpressionLanguageProvider instead.
* @deprecated since version 2.6.2, to be removed in 3.0.
* Use \Symfony\Component\DependencyInjection\ContainerBuilder::addExpressionLanguageProvider instead.
*
* @param ExpressionFunctionProviderInterface $provider
*/
public function addExpressionLanguageProvider(ExpressionFunctionProviderInterface $provider)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6.2 and will be removed in 3.0. Use the Symfony\Component\DependencyInjection\ContainerBuilder::addExpressionLanguageProvider method instead.', E_USER_DEPRECATED);
$this->expressionLanguageProviders[] = $provider;
}

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\DependencyInjection;
trigger_error('The '.__NAMESPACE__.'\SimpleXMLElement method is deprecated since version 2.5 and will be removed in 3.0.', E_USER_DEPRECATED);
use Symfony\Component\Config\Util\XmlUtils;
use Symfony\Component\ExpressionLanguage\Expression;
@ -19,7 +21,7 @@ use Symfony\Component\ExpressionLanguage\Expression;
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated Deprecated since version 2.5, to be removed in 3.0.
* @deprecated since version 2.5, to be removed in 3.0.
*/
class SimpleXMLElement extends \SimpleXMLElement
{

View File

@ -77,7 +77,7 @@ class Event
*
* @param EventDispatcherInterface $dispatcher
*
* @deprecated Deprecated in 2.4, to be removed in 3.0. The event dispatcher is passed to the listener call.
* @deprecated since version 2.4, to be removed in 3.0. The event dispatcher is passed to the listener call.
*
* @api
*/
@ -91,12 +91,14 @@ class Event
*
* @return EventDispatcherInterface
*
* @deprecated Deprecated in 2.4, to be removed in 3.0. The event dispatcher is passed to the listener call.
* @deprecated since version 2.4, to be removed in 3.0. The event dispatcher is passed to the listener call.
*
* @api
*/
public function getDispatcher()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0. The event dispatcher instance can be received in the listener call instead.', E_USER_DEPRECATED);
return $this->dispatcher;
}
@ -105,12 +107,14 @@ class Event
*
* @return string
*
* @deprecated Deprecated in 2.4, to be removed in 3.0. The event name is passed to the listener call.
* @deprecated since version 2.4, to be removed in 3.0. The event name is passed to the listener call.
*
* @api
*/
public function getName()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0. The event name can be received in the listener call instead.', E_USER_DEPRECATED);
return $this->name;
}
@ -119,7 +123,7 @@ class Event
*
* @param string $name The event name.
*
* @deprecated Deprecated in 2.4, to be removed in 3.0. The event name is passed to the listener call.
* @deprecated since version 2.4, to be removed in 3.0. The event name is passed to the listener call.
*
* @api
*/

View File

@ -592,12 +592,12 @@ class ButtonBuilder implements \IteratorAggregate, FormBuilderInterface
*
* @return bool Always returns false.
*
* @deprecated since version 2.3, to be removed in 3.0. Use
* {@link getInheritData()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link getInheritData()} instead.
*/
public function getVirtual()
{
trigger_error('ButtonBuilder::getVirtual() is deprecated since version 2.3 and will be removed in 3.0. Use FormConfigBuilder::getInheritData() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Form\FormConfigBuilder::getInheritData method instead.', E_USER_DEPRECATED);
return false;
}

View File

@ -11,10 +11,10 @@
namespace Symfony\Component\Form\Deprecated;
trigger_error('Constants ROUND_HALFEVEN, ROUND_HALFUP and ROUND_HALFDOWN on class NumberToLocalizedStringTransformer were deprecated in Symfony 2.4 and will be removed in 3.0. Use ROUND_HALF_EVEN, ROUND_HALF_UP and ROUND_HALF_DOWN instead.', E_USER_DEPRECATED);
trigger_error('Constants ROUND_HALFEVEN, ROUND_HALFUP and ROUND_HALFDOWN in class NumberToLocalizedStringTransformer are deprecated since version 2.4 and will be removed in 3.0. Use ROUND_HALF_EVEN, ROUND_HALF_UP and ROUND_HALF_DOWN instead.', E_USER_DEPRECATED);
/**
* @deprecated since 2.7, to be removed in 3.0.
* @deprecated since version 2.7, to be removed in 3.0.
* @internal
*/
final class NumberToLocalizedStringTransformer

View File

@ -11,11 +11,13 @@
namespace Symfony\Component\Form\Exception;
trigger_error('The '.__NAMESPACE__.'\AlreadyBoundException class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Form\Exception\AlreadySubmittedException class instead.', E_USER_DEPRECATED);
/**
* Alias of {@link AlreadySubmittedException}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link AlreadySubmittedException} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link AlreadySubmittedException} instead.
*/
class AlreadyBoundException extends LogicException
{

View File

@ -199,10 +199,12 @@ class ChoiceList implements ChoiceListInterface
/**
* {@inheritdoc}
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForChoices(array $choices)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
$choices = $this->fixChoices($choices);
$indices = array();
@ -225,10 +227,12 @@ class ChoiceList implements ChoiceListInterface
/**
* {@inheritdoc}
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForValues(array $values)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
$values = $this->fixValues($values);
$indices = array();

View File

@ -139,7 +139,7 @@ interface ChoiceListInterface
*
* @return array An array of indices with ascending, 0-based numeric keys
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForChoices(array $choices);
@ -159,7 +159,7 @@ interface ChoiceListInterface
*
* @return array An array of indices with ascending, 0-based numeric keys
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForValues(array $values);
}

View File

@ -106,10 +106,12 @@ abstract class LazyChoiceList implements ChoiceListInterface
/**
* {@inheritdoc}
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForChoices(array $choices)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
if (!$this->choiceList) {
$this->load();
}
@ -120,10 +122,12 @@ abstract class LazyChoiceList implements ChoiceListInterface
/**
* {@inheritdoc}
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForValues(array $values)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
if (!$this->choiceList) {
$this->load();
}

View File

@ -187,10 +187,12 @@ class ObjectChoiceList extends ChoiceList
/**
* {@inheritdoc}
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function getIndicesForChoices(array $choices)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
if (!$this->valuePath) {
return parent::getIndicesForChoices($choices);
}

View File

@ -76,21 +76,21 @@ class NumberToLocalizedStringTransformer implements DataTransformerInterface
/**
* Alias for {@link self::ROUND_HALF_EVEN}.
*
* @deprecated Deprecated as of Symfony 2.4, to be removed in Symfony 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
const ROUND_HALFEVEN = Deprecated::ROUND_HALFEVEN;
/**
* Alias for {@link self::ROUND_HALF_UP}.
*
* @deprecated Deprecated as of Symfony 2.4, to be removed in Symfony 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
const ROUND_HALFUP = Deprecated::ROUND_HALFUP;
/**
* Alias for {@link self::ROUND_HALF_DOWN}.
*
* @deprecated Deprecated as of Symfony 2.4, to be removed in Symfony 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
const ROUND_HALFDOWN = Deprecated::ROUND_HALFDOWN;

View File

@ -81,11 +81,13 @@ class FixCheckboxInputListener implements EventSubscriberInterface
/**
* Alias of {@link preSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link preSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link preSubmit()} instead.
*/
public function preBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the preSubmit() method instead.', E_USER_DEPRECATED);
$this->preSubmit($event);
}

View File

@ -63,11 +63,13 @@ class FixRadioInputListener implements EventSubscriberInterface
/**
* Alias of {@link preSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link preSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link preSubmit()} instead.
*/
public function preBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the preSubmit() method instead.', E_USER_DEPRECATED);
$this->preSubmit($event);
}

View File

@ -46,11 +46,13 @@ class FixUrlProtocolListener implements EventSubscriberInterface
/**
* Alias of {@link onSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link onSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link onSubmit()} instead.
*/
public function onBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the onSubmit() method instead.', E_USER_DEPRECATED);
$this->onSubmit($event);
}

View File

@ -129,11 +129,13 @@ class MergeCollectionListener implements EventSubscriberInterface
/**
* Alias of {@link onSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link onSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link onSubmit()} instead.
*/
public function onBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the onSubmit() method instead.', E_USER_DEPRECATED);
$this->onSubmit($event);
}
}

View File

@ -184,22 +184,26 @@ class ResizeFormListener implements EventSubscriberInterface
/**
* Alias of {@link preSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link preSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link preSubmit()} instead.
*/
public function preBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the preSubmit() method instead.', E_USER_DEPRECATED);
$this->preSubmit($event);
}
/**
* Alias of {@link onSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link onSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link onSubmit()} instead.
*/
public function onBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the onSubmit() method instead.', E_USER_DEPRECATED);
$this->onSubmit($event);
}
}

View File

@ -40,11 +40,13 @@ class TrimListener implements EventSubscriberInterface
/**
* Alias of {@link preSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link preSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link preSubmit()} instead.
*/
public function preBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the preSubmit() method instead.', E_USER_DEPRECATED);
$this->preSubmit($event);
}

View File

@ -11,7 +11,7 @@
namespace Symfony\Component\Form\Extension\Csrf\CsrfProvider;
trigger_error('Symfony\Component\Form\Extension\Csrf\CsrfProvider\CsrfProviderAdapter was deprecated in version 2.4 and will be removed in version 3.0. Please use Symfony\Component\Security\Csrf\CsrfTokenManager instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\CsrfProviderAdapter class is deprecated since version 2.4 and will be removed in version 3.0. Use the Symfony\Component\Security\Csrf\CsrfTokenManager class instead.', E_USER_DEPRECATED);
use Symfony\Component\Form\Exception\BadMethodCallException;
use Symfony\Component\Security\Csrf\CsrfToken;
@ -24,7 +24,7 @@ use Symfony\Component\Security\Csrf\CsrfTokenManagerInterface;
* @since 2.4
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.4, to be removed in Symfony 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
class CsrfProviderAdapter implements CsrfTokenManagerInterface
{

View File

@ -11,8 +11,6 @@
namespace Symfony\Component\Form\Extension\Csrf\CsrfProvider;
trigger_error('Symfony\Component\Form\Extension\Csrf\CsrfProvider\CsrfProviderInterface was deprecated in version 2.4 and will be removed in version 3.0. Please use Symfony\Component\Security\Csrf\CsrfTokenManagerInterface instead.', E_USER_DEPRECATED);
/**
* Marks classes able to provide CSRF protection.
*
@ -29,9 +27,8 @@ trigger_error('Symfony\Component\Form\Extension\Csrf\CsrfProvider\CsrfProviderIn
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated since version 2.4, to be removed in Symfony 3.0. Use
* {@link \Symfony\Component\Security\Csrf\CsrfTokenManagerInterface}
* instead.
* @deprecated since version 2.4, to be removed in 3.0.
* Use {@link \Symfony\Component\Security\Csrf\CsrfTokenManagerInterface} instead.
*/
interface CsrfProviderInterface
{

View File

@ -11,7 +11,7 @@
namespace Symfony\Component\Form\Extension\Csrf\CsrfProvider;
trigger_error('Symfony\Component\Form\Extension\Csrf\CsrfProvider\CsrfTokenManagerAdapter was deprecated in version 2.4 and will be removed in version 3.0. Please use Symfony\Component\Security\Csrf\CsrfTokenManager instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\CsrfTokenManagerAdapter is deprecated since version 2.4 and will be removed in version 3.0. Use the Symfony\Component\Security\Csrf\CsrfTokenManager class instead.', E_USER_DEPRECATED);
use Symfony\Component\Security\Csrf\CsrfToken;
use Symfony\Component\Security\Csrf\CsrfTokenManagerInterface;
@ -22,7 +22,7 @@ use Symfony\Component\Security\Csrf\CsrfTokenManagerInterface;
* @since 2.4
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.4, to be removed in Symfony 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
class CsrfTokenManagerAdapter implements CsrfProviderInterface
{

View File

@ -11,7 +11,7 @@
namespace Symfony\Component\Form\Extension\Csrf\CsrfProvider;
trigger_error('Symfony\Component\Security\Csrf\CsrfTokenManager was deprecated in version 2.4 and will be removed in version 3.0. Please use \Symfony\Component\Security\Csrf\TokenStorage\NativeSessionTokenStorage instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\DefaultCsrfProvider is deprecated since version 2.4 and will be removed in version 3.0. Use the \Symfony\Component\Security\Csrf\TokenStorage\NativeSessionTokenStorage class instead.', E_USER_DEPRECATED);
/**
* Default implementation of CsrfProviderInterface.
@ -21,8 +21,8 @@ trigger_error('Symfony\Component\Security\Csrf\CsrfTokenManager was deprecated i
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.4, to be removed in Symfony 3.0. Use
* {@link \Symfony\Component\Security\Csrf\CsrfTokenManager} in
* @deprecated since version 2.4, to be removed in 3.0.
* Use {@link \Symfony\Component\Security\Csrf\CsrfTokenManager} in
* combination with {@link \Symfony\Component\Security\Csrf\TokenStorage\NativeSessionTokenStorage}
* instead.
*/

View File

@ -11,7 +11,7 @@
namespace Symfony\Component\Form\Extension\Csrf\CsrfProvider;
trigger_error('Symfony\Component\Security\Csrf\CsrfTokenManager was deprecated in version 2.4 and will be removed in version 3.0. Please use Symfony\Component\Security\Csrf\TokenStorage\SessionTokenStorage instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\SessionCsrfProvider is deprecated since version 2.4 and will be removed in version 3.0. Use the Symfony\Component\Security\Csrf\TokenStorage\SessionTokenStorage class instead.', E_USER_DEPRECATED);
use Symfony\Component\HttpFoundation\Session\Session;
@ -23,8 +23,8 @@ use Symfony\Component\HttpFoundation\Session\Session;
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.4, to be removed in Symfony 3.0. Use
* {@link \Symfony\Component\Security\Csrf\CsrfTokenManager} in
* @deprecated since version 2.4, to be removed in 3.0.
* Use {@link \Symfony\Component\Security\Csrf\CsrfTokenManager} in
* combination with {@link \Symfony\Component\Security\Csrf\TokenStorage\SessionTokenStorage}
* instead.
*/

View File

@ -118,11 +118,13 @@ class CsrfValidationListener implements EventSubscriberInterface
/**
* Alias of {@link preSubmit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link preSubmit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link preSubmit()} instead.
*/
public function preBind(FormEvent $event)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the preSubmit() method instead.', E_USER_DEPRECATED);
$this->preSubmit($event);
}
}

View File

@ -0,0 +1,27 @@
<?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Symfony\Component\Form\Extension\Validator\Constraints\Deprecated;
trigger_error('Constant ERR_INVALID in class Symfony\Component\Form\Extension\Validator\Constraints\Form is deprecated since version 2.6 and will be removed in 3.0. Use NOT_SYNCHRONIZED_ERROR constant instead.', E_USER_DEPRECATED);
/**
* @deprecated since version 2.7, to be removed in 3.0.
* @internal
*/
final class Form
{
const ERR_INVALID = 1;
private function __construct()
{
}
}

View File

@ -11,6 +11,7 @@
namespace Symfony\Component\Form\Extension\Validator\Constraints;
use Symfony\Component\Form\Extension\Validator\Constraints\Deprecated\Form as Deprecated;
use Symfony\Component\Validator\Constraint;
/**
@ -22,10 +23,10 @@ class Form extends Constraint
const NO_SUCH_FIELD_ERROR = 2;
/**
* @deprecated Deprecated since Symfony 2.6, to be removed in 3.0. Use
* {@self NOT_SYNCHRONIZED_ERROR} instead.
* @deprecated since version 2.6, to be removed in 3.0.
* Use {@self NOT_SYNCHRONIZED_ERROR} instead.
*/
const ERR_INVALID = 1;
const ERR_INVALID = Deprecated::ERR_INVALID;
protected static $errorNames = array(
self::NOT_SYNCHRONIZED_ERROR => 'NOT_SYNCHRONIZED_ERROR',

View File

@ -507,7 +507,7 @@ class Form implements \IteratorAggregate, FormInterface
public function submit($submittedData, $clearMissing = true)
{
if ($submittedData instanceof Request) {
trigger_error('Passing a Symfony\Component\HttpFoundation\Request object to '.__CLASS__.'::bind() and '.__METHOD__.'() is deprecated since 2.3 and will be removed in 3.0, please use '.__CLASS__.'::handleRequest(). If you want to test whether the form was submitted separately, you can use the method '.__CLASS__.'::isSubmitted()', E_USER_DEPRECATED);
trigger_error('Passing a Symfony\Component\HttpFoundation\Request object to the '.__CLASS__.'::bind and '.__METHOD__.' methods is deprecated since 2.3 and will be removed in 3.0. Use the '.__CLASS__.'::handleRequest method instead. If you want to test whether the form was submitted separately, you can use the '.__CLASS__.'::isSubmitted method.', E_USER_DEPRECATED);
}
if ($this->submitted) {
@ -676,15 +676,15 @@ class Form implements \IteratorAggregate, FormInterface
/**
* Alias of {@link submit()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link submit()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link submit()} instead.
*/
public function bind($submittedData)
{
// This method is deprecated for Request too, but the error is
// triggered in Form::submit() method.
if (!$submittedData instanceof Request) {
trigger_error(__METHOD__.'() is deprecated since 2.3 and will be removed in 3.0. Please use '.__CLASS__.'::submit() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the '.__CLASS__.'::submit method instead.', E_USER_DEPRECATED);
}
return $this->submit($submittedData);
@ -719,12 +719,12 @@ class Form implements \IteratorAggregate, FormInterface
/**
* Alias of {@link isSubmitted()}.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link isSubmitted()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link isSubmitted()} instead.
*/
public function isBound()
{
trigger_error(__METHOD__.'() is deprecated since 2.3 and will be removed in 3.0. Please use '.__CLASS__.'::isSubmitted() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the '.__CLASS__.'::isSubmitted method instead.', E_USER_DEPRECATED);
return $this->submitted;
}
@ -843,12 +843,12 @@ class Form implements \IteratorAggregate, FormInterface
*
* @return string A string representation of all errors
*
* @deprecated Deprecated since version 2.5, to be removed in 3.0. Use
* {@link getErrors()} instead and cast the result to a string.
* @deprecated since version 2.5, to be removed in 3.0.
* Use {@link getErrors()} instead and cast the result to a string.
*/
public function getErrorsAsString($level = 0)
{
trigger_error('Form::getErrorsAsString() is deprecated since 2.5 and will be removed in 3.0. Please use Form::getErrors(true, false) instead and cast the result to a string.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.5 and will be removed in 3.0. Use the Form::getErrors(true, false) method instead and cast the result to a string.', E_USER_DEPRECATED);
return self::indent((string) $this->getErrors(true, false), $level);
}

View File

@ -351,12 +351,12 @@ class FormConfigBuilder implements FormConfigBuilderInterface
*
* @return FormConfigBuilder The configuration object.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link getInheritData()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link getInheritData()} instead.
*/
public function getVirtual()
{
trigger_error('FormConfigBuilder::getVirtual() is deprecated since version 2.3 and will be removed in 3.0. Use FormConfigBuilder::getInheritData() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the FormConfigBuilder::getInheritData() method instead.', E_USER_DEPRECATED);
return $this->getInheritData();
}
@ -717,12 +717,12 @@ class FormConfigBuilder implements FormConfigBuilderInterface
*
* @return FormConfigBuilder The configuration object.
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link setInheritData()} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link setInheritData()} instead.
*/
public function setVirtual($inheritData)
{
trigger_error('FormConfigBuilder::setVirtual() is deprecated since version 2.3 and will be removed in 3.0. Use FormConfigBuilder::setInheritData() instead.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3 and will be removed in 3.0. Use the FormConfigBuilder::setInheritData() method instead.', E_USER_DEPRECATED);
$this->setInheritData($inheritData);
}

View File

@ -14,13 +14,14 @@ namespace Symfony\Component\Form\Tests\Extension\Core\Type;
use Symfony\Component\Form\Test\TypeTestCase as BaseTypeTestCase;
/**
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use Symfony\Component\Form\Test\TypeTestCase instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Form\Test\TypeTestCase} instead.
*/
abstract class TypeTestCase extends BaseTypeTestCase
{
protected function setUp()
{
trigger_error('Abstract class "Symfony\Component\Form\Tests\Extension\Core\Type\TypeTestCase" is deprecated since version 2.3 and will be removed in 3.0. Use "Symfony\Component\Form\Test\TypeTestCase" instead.', E_USER_DEPRECATED);
trigger_error('Abstract class '.__CLASS__.' is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Form\Test\TypeTestCase class instead.', E_USER_DEPRECATED);
parent::setUp();
}
}

View File

@ -14,7 +14,8 @@ namespace Symfony\Component\Form\Tests;
use Symfony\Component\Form\Test\FormIntegrationTestCase as BaseFormIntegrationTestCase;
/**
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use Symfony\Component\Form\Test\FormIntegrationTestCase instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Form\Test\FormIntegrationTestCase} instead.
*/
abstract class FormIntegrationTestCase extends BaseFormIntegrationTestCase
{
@ -23,7 +24,7 @@ abstract class FormIntegrationTestCase extends BaseFormIntegrationTestCase
*/
protected function setUp()
{
trigger_error('This class is deprecated. Use Symfony\Component\Form\Test\FormIntegrationTestCase instead.', E_USER_DEPRECATED);
trigger_error('The '.__CLASS__.' class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Form\Test\FormIntegrationTestCase class instead.', E_USER_DEPRECATED);
parent::setUp();
}
}

View File

@ -14,7 +14,8 @@ namespace Symfony\Component\Form\Tests;
use Symfony\Component\Form\Test\FormPerformanceTestCase as BaseFormPerformanceTestCase;
/**
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use Symfony\Component\Form\Test\FormPerformanceTestCase instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Form\Test\FormPerformanceTestCase} instead.
*/
abstract class FormPerformanceTestCase extends BaseFormPerformanceTestCase
{
@ -23,7 +24,7 @@ abstract class FormPerformanceTestCase extends BaseFormPerformanceTestCase
*/
protected function setUp()
{
trigger_error('This class is deprecated. Use Symfony\Component\Form\Test\FormPerformanceTestCase instead.', E_USER_DEPRECATED);
trigger_error('The '.__CLASS__.' class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Form\Test\FormPerformanceTestCase class instead.', E_USER_DEPRECATED);
parent::setUp();
}
}

View File

@ -11,8 +11,6 @@
namespace Symfony\Component\Form\Util;
trigger_error('Symfony\Component\Form\Util\VirtualFormAwareIterator is deprecated since Symfony 2.3 and will be removed in 3.0. Use Symfony\Component\Form\Util\InheritDataAwareIterator instead.', E_USER_DEPRECATED);
/**
* Iterator that traverses an array of forms.
*
@ -22,11 +20,26 @@ trigger_error('Symfony\Component\Form\Util\VirtualFormAwareIterator is deprecate
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link InheritDataAwareIterator} instead.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link InheritDataAwareIterator} instead.
*/
class VirtualFormAwareIterator extends \IteratorIterator implements \RecursiveIterator
{
public function __construct(\Traversable $iterator)
{
/*
* Prevent to trigger deprecation notice when already using the
* InheritDataAwareIterator class that extends this deprecated one.
* The {@link Symfony\Component\Form\Util\InheritDataAwareIterator::__construct} method
* forces this argument to false.
*/
if (__CLASS__ === get_class($this)) {
trigger_error('The '.__CLASS__.' class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Form\Util\InheritDataAwareIterator class instead.', E_USER_DEPRECATED);
}
parent::__construct($iterator);
}
/**
* {@inheritdoc}
*/

View File

@ -169,12 +169,14 @@ class FlashBag implements FlashBagInterface, \IteratorAggregate
/**
* Returns an iterator for flashes.
*
* @deprecated Will be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*
* @return \ArrayIterator An \ArrayIterator instance
*/
public function getIterator()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
return new \ArrayIterator($this->all());
}
}

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\HttpFoundation\Session\Storage\Handler;
trigger_error('The '.__NAMESPACE__.'\LegacyPdoSessionHandler class is deprecated since version 2.6 and will be removed in 3.0. Use the Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler class instead.', E_USER_DEPRECATED);
/**
* Session handler using a PDO connection to read and write data.
*
@ -24,7 +26,7 @@ namespace Symfony\Component\HttpFoundation\Session\Storage\Handler;
* @author Michael Williams <michael.williams@funsational.com>
* @author Tobias Schultze <http://tobion.de>
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0. Use
* @deprecated since version 2.6, to be removed in 3.0. Use
* {@link PdoSessionHandler} instead.
*/
class LegacyPdoSessionHandler implements \SessionHandlerInterface
@ -77,8 +79,6 @@ class LegacyPdoSessionHandler implements \SessionHandlerInterface
throw new \InvalidArgumentException(sprintf('"%s" requires PDO error mode attribute be set to throw Exceptions (i.e. $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION))', __CLASS__));
}
trigger_error('"Symfony\Component\HttpFoundation\Session\Storage\Handler\LegacyPdoSessionHandler" is deprecated since version 2.6 and will be removed in 3.0. Use "Symfony\Component\HttpFoundation\Session\Storage\Handler\PdoSessionHandler" instead.', E_USER_DEPRECATED);
$this->pdo = $pdo;
$dbOptions = array_merge(array(
'db_id_col' => 'sess_id',

View File

@ -34,10 +34,11 @@ class TraceableEventDispatcher extends BaseTraceableEventDispatcher
*
* @param Profiler|null $profiler A Profiler instance
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function setProfiler(Profiler $profiler = null)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
}
/**

View File

@ -11,14 +11,14 @@
namespace Symfony\Component\HttpKernel\DependencyInjection;
trigger_error('Class "Symfony\Component\HttpKernel\DependencyInjection\RegisterListenersPass" is deprecated since 2.5 and will be removed in 3.0. Use "Symfony\Component\EventDispatcher\DependencyInjection\RegisterListenersPass" instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\RegisterListenersPass is deprecated since version 2.5 and will be removed in 3.0. Use the Symfony\Component\EventDispatcher\DependencyInjection\RegisterListenersPass class instead.', E_USER_DEPRECATED);
use Symfony\Component\EventDispatcher\DependencyInjection\RegisterListenersPass as BaseRegisterListenersPass;
/**
* Compiler pass to register tagged services for an event dispatcher.
*
* @deprecated Deprecated in 2.5, to be removed in 3.0. Use Symfony\Component\EventDispatcher\DependencyInjection\RegisterListenersPass instead.
* @deprecated since version 2.5, to be removed in 3.0. Use the Symfony\Component\EventDispatcher\DependencyInjection\RegisterListenersPass class instead.
*/
class RegisterListenersPass extends BaseRegisterListenersPass
{

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\HttpKernel\EventListener;
trigger_error('The '.__NAMESPACE__.'\ErrorsLoggerListener class is deprecated since version 2.6 and will be removed in 3.0. Use the Symfony\Component\HttpKernel\EventListener\DebugHandlersListener class instead.', E_USER_DEPRECATED);
use Psr\Log\LoggerInterface;
use Symfony\Component\Debug\ErrorHandler;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
@ -22,12 +24,11 @@ use Symfony\Component\HttpKernel\KernelEvents;
* @author Colin Frei <colin@colinfrei.com>
* @author Konstantin Myakshin <koc-dp@yandex.ru>
*
* @deprecated since 2.6, to be removed in 3.0. Use DebugHandlersListener instead.
* @deprecated since version 2.6, to be removed in 3.0. Use the DebugHandlersListener class instead.
*/
class ErrorsLoggerListener implements EventSubscriberInterface
{
private $channel;
private $logger;
public function __construct($channel, LoggerInterface $logger = null)

View File

@ -11,12 +11,14 @@
namespace Symfony\Component\HttpKernel\EventListener;
trigger_error('The '.__NAMESPACE__.'\EsiListener class is deprecated since version 2.6 and will be removed in 3.0. Use the Symfony\Component\HttpKernel\EventListener\SurrogateListener class instead.', E_USER_DEPRECATED);
/**
* EsiListener adds a Surrogate-Control HTTP header when the Response needs to be parsed for ESI.
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0. Use SurrogateListener instead
* @deprecated since version 2.6, to be removed in 3.0. Use SurrogateListener instead
*/
class EsiListener extends SurrogateListener
{

View File

@ -116,7 +116,7 @@ class ExceptionListener implements EventSubscriberInterface
'logger' => $this->logger instanceof DebugLoggerInterface ? $this->logger : null,
// keep for BC -- as $format can be an argument of the controller callable
// see src/Symfony/Bundle/TwigBundle/Controller/ExceptionController.php
// @deprecated in 2.4, to be removed in 3.0
// @deprecated since version 2.4, to be removed in 3.0
'format' => $request->getRequestFormat(),
);
$request = $request->duplicate(null, null, $attributes);

View File

@ -88,12 +88,14 @@ class FragmentListener implements EventSubscriberInterface
}
/**
* @deprecated Deprecated since 2.3.19, to be removed in 3.0.
* @deprecated since version 2.3.19, to be removed in 3.0.
*
* @return string[]
*/
protected function getLocalIpAddresses()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.3.19 and will be removed in 3.0.', E_USER_DEPRECATED);
return array('127.0.0.1', 'fe80::1', '::1');
}

View File

@ -54,10 +54,12 @@ class LocaleListener implements EventSubscriberInterface
*
* @param Request|null $request A Request instance
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function setRequest(Request $request = null)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
if (null === $request) {
return;
}

View File

@ -22,7 +22,7 @@ use Symfony\Component\HttpFoundation\RequestStack;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
/**
* ProfilerListener collects data for the current request by listening to the onKernelResponse event.
* ProfilerListener collects data for the current request by listening to the kernel events.
*
* @author Fabien Potencier <fabien@symfony.com>
*/
@ -49,6 +49,13 @@ class ProfilerListener implements EventSubscriberInterface
*/
public function __construct(Profiler $profiler, RequestMatcherInterface $matcher = null, $onlyException = false, $onlyMasterRequests = false, RequestStack $requestStack = null)
{
if (null === $requestStack) {
// Prevent the deprecation notice to be triggered all the time.
// The onKernelRequest() method fires some logic only when the
// RequestStack instance is not provided as a dependency.
trigger_error('Since version 2.4, the '.__METHOD__.' method must accept a RequestStack instance to get the request instead of using the '.__CLASS__.'::onKernelRequest method that will be removed in 3.0.', E_USER_DEPRECATED);
}
$this->profiler = $profiler;
$this->matcher = $matcher;
$this->onlyException = (bool) $onlyException;
@ -73,7 +80,7 @@ class ProfilerListener implements EventSubscriberInterface
}
/**
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function onKernelRequest(GetResponseEvent $event)
{

View File

@ -67,6 +67,10 @@ class RouterListener implements EventSubscriberInterface
throw new \InvalidArgumentException('You must either pass a RequestContext or the matcher must implement RequestContextAwareInterface.');
}
if (!$requestStack instanceof RequestStack) {
trigger_error('The '.__METHOD__.' method now requires a RequestStack instance as '.__CLASS__.'::setRequest method will not be supported anymore in 3.0.');
}
$this->matcher = $matcher;
$this->context = $context ?: $matcher->getContext();
$this->requestStack = $requestStack;
@ -82,13 +86,21 @@ class RouterListener implements EventSubscriberInterface
*
* @param Request|null $request A Request instance
*
* @deprecated Deprecated since version 2.4, to be moved to a private function in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function setRequest(Request $request = null)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be made private in 3.0.', E_USER_DEPRECATED);
$this->setCurrentRequest($request);
}
private function setCurrentRequest(Request $request = null)
{
if (null !== $request && $this->request !== $request) {
$this->context->fromRequest($request);
}
$this->request = $request;
}
@ -98,7 +110,7 @@ class RouterListener implements EventSubscriberInterface
return; // removed when requestStack is required
}
$this->setRequest($this->requestStack->getParentRequest());
$this->setCurrentRequest($this->requestStack->getParentRequest());
}
public function onKernelRequest(GetResponseEvent $event)
@ -106,11 +118,11 @@ class RouterListener implements EventSubscriberInterface
$request = $event->getRequest();
// initialize the context that is also used by the generator (assuming matcher and generator share the same context instance)
// we call setRequest even if most of the time, it has already been done to keep compatibility
// we call setCurrentRequest even if most of the time, it has already been done to keep compatibility
// with frameworks which do not use the Symfony service container
// when we have a RequestStack, no need to do it
if (null !== $this->requestStack) {
$this->setRequest($request);
$this->setCurrentRequest($request);
}
if ($request->attributes->has('_controller')) {

View File

@ -11,13 +11,13 @@
namespace Symfony\Component\HttpKernel\Exception;
trigger_error('Symfony\Component\HttpKernel\Exception\FatalErrorException is deprecated since version 2.3 and will be removed in 3.0. Use the same class from the Debug component instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\FatalErrorException class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Debug\Exception\FatalErrorException class instead.', E_USER_DEPRECATED);
/**
* Fatal Error Exception.
*
* @author Konstanton Myakshin <koc-dp@yandex.ru>
*
* @deprecated Deprecated in 2.3, to be removed in 3.0. Use the same class from the Debug component instead.
* @deprecated since version 2.3, to be removed in 3.0. Use the same class from the Debug component instead.
*/
class_exists('Symfony\Component\Debug\Exception\FatalErrorException');

View File

@ -11,7 +11,7 @@
namespace Symfony\Component\HttpKernel\Exception;
trigger_error('Symfony\Component\HttpKernel\Exception\FlattenException is deprecated since version 2.3 and will be removed in 3.0. Use the same class from the Debug component instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\FlattenException class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Debug\Exception\FlattenException class instead.', E_USER_DEPRECATED);
/**
* FlattenException wraps a PHP Exception to be able to serialize it.
@ -20,6 +20,6 @@ trigger_error('Symfony\Component\HttpKernel\Exception\FlattenException is deprec
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated Deprecated in 2.3, to be removed in 3.0. Use the same class from the Debug component instead.
* @deprecated since version 2.3, to be removed in 3.0. Use the same class from the Debug component instead.
*/
class_exists('Symfony\Component\Debug\Exception\FlattenException');

View File

@ -76,10 +76,12 @@ class FragmentHandler
*
* @param Request|null $request A Request instance
*
* @deprecated Deprecated since version 2.4, to be removed in 3.0.
* @deprecated since version 2.4, to be removed in 3.0.
*/
public function setRequest(Request $request = null)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0.', E_USER_DEPRECATED);
$this->request = $request;
}

View File

@ -75,10 +75,12 @@ class Esi implements SurrogateInterface
*
* @return bool true if one surrogate has ESI/1.0 capability, false otherwise
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0. Use hasSurrogateCapability() instead
* @deprecated since version 2.6, to be removed in 3.0. Use hasSurrogateCapability() instead
*/
public function hasSurrogateEsiCapability(Request $request)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the hasSurrogateCapability() method instead.', E_USER_DEPRECATED);
if (null === $value = $request->headers->get('Surrogate-Capability')) {
return false;
}
@ -101,10 +103,12 @@ class Esi implements SurrogateInterface
*
* @param Request $request A Request instance
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0. Use addSurrogateCapability() instead
* @deprecated since version 2.6, to be removed in 3.0. Use addSurrogateCapability() instead
*/
public function addSurrogateEsiCapability(Request $request)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the addSurrogateCapability() method instead.', E_USER_DEPRECATED);
$current = $request->headers->get('Surrogate-Capability');
$new = 'symfony2="ESI/1.0"';
@ -144,10 +148,12 @@ class Esi implements SurrogateInterface
*
* @return bool true if the Response needs to be parsed, false otherwise
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0. Use needsParsing() instead
* @deprecated since version 2.6, to be removed in 3.0. Use needsParsing() instead
*/
public function needsEsiParsing(Response $response)
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the needsParsing() method instead.', E_USER_DEPRECATED);
if (!$control = $response->headers->get('Surrogate-Control')) {
return false;
}

View File

@ -15,6 +15,8 @@
namespace Symfony\Component\HttpKernel\HttpCache;
trigger_error('The '.__NAMESPACE__.'\EsiResponseCacheStrategy class is deprecated since version 2.6 and will be removed in 3.0. Use the Symfony\Component\HttpKernel\HttpCache\ResponseCacheStrategy class instead.', E_USER_DEPRECATED);
/**
* EsiResponseCacheStrategy knows how to compute the Response cache HTTP header
* based on the different ESI response cache headers.
@ -24,7 +26,7 @@ namespace Symfony\Component\HttpKernel\HttpCache;
*
* @author Fabien Potencier <fabien@symfony.com>
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0. Use ResponseCacheStrategy instead
* @deprecated since version 2.6, to be removed in 3.0. Use ResponseCacheStrategy instead
*/
class EsiResponseCacheStrategy extends ResponseCacheStrategy implements EsiResponseCacheStrategyInterface
{

View File

@ -170,10 +170,12 @@ class HttpCache implements HttpKernelInterface, TerminableInterface
*
* @return Esi An Esi instance
*
* @deprecated Deprecated since version 2.6, to be removed in 3.0. Use getSurrogate() instead
* @deprecated since version 2.6, to be removed in 3.0. Use getSurrogate() instead
*/
public function getEsi()
{
trigger_error('The '.__METHOD__.' method is deprecated since version 2.6 and will be removed in 3.0. Use the getSurrogate() method instead.', E_USER_DEPRECATED);
if (!$this->surrogate instanceof Esi) {
throw new \LogicException('This instance of HttpCache was not set up to use ESI as surrogate handler. You must overwrite and use createSurrogate');
}

View File

@ -215,35 +215,9 @@ abstract class Kernel implements KernelInterface, TerminableInterface
}
/**
* Returns the file path for a given resource.
* {@inheritDoc}
*
* A Resource can be a file or a directory.
*
* The resource name must follow the following pattern:
*
* @<BundleName>/path/to/a/file.something
*
* where BundleName is the name of the bundle
* and the remaining part is the relative path in the bundle.
*
* If $dir is passed, and the first segment of the path is "Resources",
* this method will look for a file named:
*
* $dir/<BundleName>/path/without/Resources
*
* before looking in the bundle resource folder.
*
* @param string $name A resource name to locate
* @param string $dir A directory where to look for the resource first
* @param bool $first Whether to return the first path or paths for all matching bundles
*
* @return string|array The absolute path of the resource or an array if $first is false
*
* @throws \InvalidArgumentException if the file cannot be found or the name is not valid
* @throws \RuntimeException if the name contains invalid/unsafe
* @throws \RuntimeException if a custom resource is hidden by a resource in a derived bundle
*
* @api
* @throws \RuntimeException if a custom resource is hidden by a resource in a derived bundle
*/
public function locateResource($name, $dir = null, $first = true)
{

View File

@ -90,15 +90,17 @@ interface KernelInterface extends HttpKernelInterface, \Serializable
*
* The resource name must follow the following pattern:
*
* @BundleName/path/to/a/file.something
* "@BundleName/path/to/a/file.something"
*
* where BundleName is the name of the bundle
* and the remaining part is the relative path in the bundle.
*
* If $dir is passed, and the first segment of the path is Resources,
* If $dir is passed, and the first segment of the path is "Resources",
* this method will look for a file named:
*
* $dir/BundleName/path/without/Resources
* $dir/<BundleName>/path/without/Resources
*
* before looking in the bundle resource folder.
*
* @param string $name A resource name to locate
* @param string $dir A directory where to look for the resource first

View File

@ -27,28 +27,28 @@ interface LoggerInterface extends PsrLogger
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use emergency() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use emergency() which is PSR-3 compatible.
*/
public function emerg($message, array $context = array());
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use critical() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use critical() which is PSR-3 compatible.
*/
public function crit($message, array $context = array());
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use error() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use error() which is PSR-3 compatible.
*/
public function err($message, array $context = array());
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use warning() which is PSR-3 compatible.
* @deprecated since version 2.2, to be removed in 3.0. Use warning() which is PSR-3 compatible.
*/
public function warn($message, array $context = array());
}

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\HttpKernel\Log;
trigger_error('The '.__NAMESPACE__.'\NullLogger class is deprecated since version 2.2 and will be removed in 3.0. Use the Psr\Log\NullLogger class instead from the psr/log Composer package.');
use Psr\Log\NullLogger as PsrNullLogger;
/**
@ -24,41 +26,33 @@ class NullLogger extends PsrNullLogger implements LoggerInterface
{
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use emergency() which is PSR-3 compatible.
*/
public function emerg($message, array $context = array())
{
trigger_error('The emerg() method of the NullLogger was removed. You should use the new method emergency() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.2 and will be removed in 3.0. You should use the new emergency() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
}
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use critical() which is PSR-3 compatible.
*/
public function crit($message, array $context = array())
{
trigger_error('The crit() method of the NullLogger was removed. You should use the new method critical() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.2 and will be removed in 3.0. You should use the new critical() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
}
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use error() which is PSR-3 compatible.
*/
public function err($message, array $context = array())
{
trigger_error('The err() method of the NullLogger was removed. You should use the new method error() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.2 and will be removed in 3.0. You should use the new error() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
}
/**
* @api
*
* @deprecated since 2.2, to be removed in 3.0. Use warning() which is PSR-3 compatible.
*/
public function warn($message, array $context = array())
{
trigger_error('The warn() method of the NullLogger was removed. You should use the new method warning() instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
trigger_error('The '.__METHOD__.' method is deprecated since version 2.2 and will be removed in 3.0. You should use the new warning() method instead, which is PSR-3 compatible.', E_USER_DEPRECATED);
}
}

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Exception;
trigger_error('The '.__NAMESPACE__.'\MethodArgumentNotImplementedException class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\Exception\MethodArgumentNotImplementedException class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\Exception\MethodArgumentNotImplementedException as BaseMethodArgumentNotImplementedException;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\Exception\MethodArgumentNotImplementedException as Ba
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\Exception\MethodArgumentNotImplementedException}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\Exception\MethodArgumentNotImplementedException}
* instead.
*/
class MethodArgumentNotImplementedException extends BaseMethodArgumentNotImplementedException

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Exception;
trigger_error('The '.__NAMESPACE__.'\MethodArgumentValueNotImplementedException class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\Exception\MethodArgumentValueNotImplementedException class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\Exception\MethodArgumentValueNotImplementedException as BaseMethodArgumentValueNotImplementedException;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\Exception\MethodArgumentValueNotImplementedException
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\Exception\MethodArgumentValueNotImplementedException}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\Exception\MethodArgumentValueNotImplementedException}
* instead.
*/
class MethodArgumentValueNotImplementedException extends BaseMethodArgumentValueNotImplementedException

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Exception;
trigger_error('The '.__NAMESPACE__.'\MethodNotImplementedException class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\Exception\MethodNotImplementedException class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\Exception\MethodNotImplementedException as BaseMethodNotImplementedException;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\Exception\MethodNotImplementedException as BaseMethod
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\Exception\MethodNotImplementedException}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\Exception\MethodNotImplementedException}
* instead.
*/
class MethodNotImplementedException extends BaseMethodNotImplementedException

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Exception;
trigger_error('The '.__NAMESPACE__.'\NotImplementedException class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\Exception\NotImplementedException class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\Exception\NotImplementedException as BaseNotImplementedException;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\Exception\NotImplementedException as BaseNotImplement
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\Exception\NotImplementedException}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\Exception\NotImplementedException}
* instead.
*/
class NotImplementedException extends BaseNotImplementedException

View File

@ -11,7 +11,7 @@
namespace Symfony\Component\Locale;
trigger_error('\Symfony\Component\Locale\Locale is deprecated since version 2.7, to be removed in Symfony 3.0. Use the methods provided by \Symfony\Component\Intl\Intl instead.', E_USER_DEPRECATED);
trigger_error('The '.__NAMESPACE__.'\Locale class is deprecated since version 2.7, to be removed in Symfony 3.0. Use the methods provided by the \Symfony\Component\Intl\Intl class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\Intl;
@ -20,7 +20,7 @@ use Symfony\Component\Intl\Intl;
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0.
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Locale} and {@link \Symfony\Component\Intl\Intl} instead.
*/
class Locale extends \Locale

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Stub\DateFormat;
trigger_error('The '.__NAMESPACE__.'\AmPmTransformer class is deprecated since version 2.3 and will be removed in Symfony 3.0. Use the Symfony\Component\Intl\DateFormatter\DateFormat\AmPmTransformer class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\DateFormatter\DateFormat\AmPmTransformer as BaseAmPmTransformer;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\DateFormatter\DateFormat\AmPmTransformer as BaseAmPmT
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\DateFormatter\DateFormat\AmPmTransformer}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\DateFormatter\DateFormat\AmPmTransformer}
* instead.
*/
class AmPmTransformer extends BaseAmPmTransformer

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Stub\DateFormat;
trigger_error('The '.__NAMESPACE__.'\DayOfWeekTransformer class is deprecated since version 2.3 and will be removed in Symfony 3.0. Use the Symfony\Component\Intl\DateFormatter\DateFormat\DayOfWeekTransformer class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\DateFormatter\DateFormat\DayOfWeekTransformer as BaseDayOfWeekTransformer;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\DateFormatter\DateFormat\DayOfWeekTransformer as Base
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\DateFormatter\DateFormat\DayOfWeekTransformer}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\DateFormatter\DateFormat\DayOfWeekTransformer}
* instead.
*/
class DayOfWeekTransformer extends BaseDayOfWeekTransformer

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Stub\DateFormat;
trigger_error('The '.__NAMESPACE__.'\DayOfYearTransformer class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\DateFormatter\DateFormat\DayOfYearTransformer class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\DateFormatter\DateFormat\DayOfYearTransformer as BaseDayOfYearTransformer;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\DateFormatter\DateFormat\DayOfYearTransformer as Base
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\DateFormatter\DateFormat\DayOfYearTransformer}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\DateFormatter\DateFormat\DayOfYearTransformer}
* instead.
*/
class DayOfYearTransformer extends BaseDayOfYearTransformer

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Stub\DateFormat;
trigger_error('The '.__NAMESPACE__.'\DayTransformer class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\DateFormatter\DateFormat\DayTransformer class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\DateFormatter\DateFormat\DayTransformer as BaseDayTransformer;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\DateFormatter\DateFormat\DayTransformer as BaseDayTra
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\DateFormatter\DateFormat\DayTransformer}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\DateFormatter\DateFormat\DayTransformer}
* instead.
*/
class DayTransformer extends BaseDayTransformer

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Stub\DateFormat;
trigger_error('The '.__NAMESPACE__.'\FullTransformer class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\DateFormatter\DateFormat\FullTransformer class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\DateFormatter\DateFormat\FullTransformer as BaseFullTransformer;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\DateFormatter\DateFormat\FullTransformer as BaseFullT
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\DateFormatter\DateFormat\FullTransformer}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\DateFormatter\DateFormat\FullTransformer}
* instead.
*/
class FullTransformer extends BaseFullTransformer

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Stub\DateFormat;
trigger_error('The '.__NAMESPACE__.'\Hour1200Transformer class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\DateFormatter\DateFormat\Hour1200Transformer class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\DateFormatter\DateFormat\Hour1200Transformer as BaseHour1200Transformer;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\DateFormatter\DateFormat\Hour1200Transformer as BaseH
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\DateFormatter\DateFormat\Hour1200Transformer}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\DateFormatter\DateFormat\Hour1200Transformer}
* instead.
*/
class Hour1200Transformer extends BaseHour1200Transformer

View File

@ -11,6 +11,8 @@
namespace Symfony\Component\Locale\Stub\DateFormat;
trigger_error('The '.__NAMESPACE__.'\Hour1201Transformer class is deprecated since version 2.3 and will be removed in 3.0. Use the Symfony\Component\Intl\DateFormatter\DateFormat\Hour1201Transformer class instead.', E_USER_DEPRECATED);
use Symfony\Component\Intl\DateFormatter\DateFormat\Hour1201Transformer as BaseHour1201Transformer;
/**
@ -18,8 +20,8 @@ use Symfony\Component\Intl\DateFormatter\DateFormat\Hour1201Transformer as BaseH
*
* @author Bernhard Schussek <bschussek@gmail.com>
*
* @deprecated Deprecated since version 2.3, to be removed in 3.0. Use
* {@link \Symfony\Component\Intl\DateFormatter\DateFormat\Hour1201Transformer}
* @deprecated since version 2.3, to be removed in 3.0.
* Use {@link \Symfony\Component\Intl\DateFormatter\DateFormat\Hour1201Transformer}
* instead.
*/
class Hour1201Transformer extends BaseHour1201Transformer

Some files were not shown because too many files have changed in this diff Show More