DescriptorHelper.php 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  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\Bundle\FrameworkBundle\Console\Helper;
  11. use Symfony\Bundle\FrameworkBundle\Console\Descriptor\JsonDescriptor;
  12. use Symfony\Bundle\FrameworkBundle\Console\Descriptor\MarkdownDescriptor;
  13. use Symfony\Bundle\FrameworkBundle\Console\Descriptor\TextDescriptor;
  14. use Symfony\Bundle\FrameworkBundle\Console\Descriptor\XmlDescriptor;
  15. use Symfony\Component\Console\Helper\DescriptorHelper as BaseDescriptorHelper;
  16. /**
  17. * @author Jean-François Simon <jeanfrancois.simon@sensiolabs.com>
  18. *
  19. * @internal
  20. */
  21. class DescriptorHelper extends BaseDescriptorHelper
  22. {
  23. public function __construct()
  24. {
  25. $this
  26. ->register('txt', new TextDescriptor())
  27. ->register('xml', new XmlDescriptor())
  28. ->register('json', new JsonDescriptor())
  29. ->register('md', new MarkdownDescriptor())
  30. ;
  31. }
  32. }