vendor/symfony/templating/Helper/Helper.php line 14

Open in your IDE?
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien@symfony.com>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Component\Templating\Helper;
  11. trigger_deprecation('symfony/templating', '6.4', '"%s" is deprecated since version 6.4 and will be removed in 7.0. Use Twig instead.', Helper::class);
  12. /**
  13. * Helper is the base class for all helper classes.
  14. *
  15. * Most of the time, a Helper is an adapter around an existing
  16. * class that exposes a read-only interface for templates.
  17. *
  18. * @author Fabien Potencier <fabien@symfony.com>
  19. *
  20. * @deprecated since Symfony 6.4, use Twig instead
  21. */
  22. abstract class Helper implements HelperInterface
  23. {
  24. protected $charset = 'UTF-8';
  25. /**
  26. * Sets the default charset.
  27. *
  28. * @return void
  29. */
  30. public function setCharset(string $charset)
  31. {
  32. $this->charset = $charset;
  33. }
  34. /**
  35. * Gets the default charset.
  36. */
  37. public function getCharset(): string
  38. {
  39. return $this->charset;
  40. }
  41. }