Add a deprecation note about VirtualFormAwareIterator

This commit is contained in:
Marc Morales Valldepérez 2014-11-29 11:49:07 +01:00 committed by Nicolas Grekas
parent ab4d9b8012
commit e2a19ee185

View File

@ -25,6 +25,15 @@ namespace Symfony\Component\Form\Util;
*/
class VirtualFormAwareIterator extends \IteratorIterator implements \RecursiveIterator
{
public function __construct(\Traversable $iterator)
{
parent::__construct($iterator);
if ('Symfony\Component\Form\Util\VirtualFormAwareIterator' === get_class()) {
trigger_error('class VirtualFormAwareIterator is deprecated since version 2.7 and will be removed in 3.0. Use InheritDataAwareIterator instead.', E_USER_DEPRECATED);
}
}
/**
* {@inheritdoc}
*/