* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Console\Descriptor; use Symfony\Component\Console\Application; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Exception\InvalidArgumentException; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputDefinition; use Symfony\Component\Console\Input\InputOption; use Symfony\Component\Console\Output\OutputInterface; /** * @author Jean-François Simon * * @internal */ abstract class Descriptor implements DescriptorInterface { /** * @var OutputInterface */ protected $output; /** * {@inheritdoc} */ public function describe(OutputInterface $output, object $object, array $options = []) { $this->output = $output; switch (true) { case $object instanceof InputArgument: $this->describeInputArgument($object, $options); break; case $object instanceof InputOption: $this->describeInputOption($object, $options); break; case $object instanceof InputDefinition: $this->describeInputDefinition($object, $options); break; case $object instanceof Command: $this->describeCommand($object, $options); break; case $object instanceof Application: $this->describeApplication($object, $options); break; default: throw new InvalidArgumentException(sprintf('Object of type "%s" is not describable.', get_debug_type($object))); } } /** * Writes content to output. */ protected function write(string $content, bool $decorated = false) { $this->output->write($content, false, $decorated ? OutputInterface::OUTPUT_NORMAL : OutputInterface::OUTPUT_RAW); } /** * Describes an InputArgument instance. */ abstract protected function describeInputArgument(InputArgument $argument, array $options = []); /** * Describes an InputOption instance. */ abstract protected function describeInputOption(InputOption $option, array $options = []); /** * Describes an InputDefinition instance. */ abstract protected function describeInputDefinition(InputDefinition $definition, array $options = []); /** * Describes a Command instance. */ abstract protected function describeCommand(Command $command, array $options = []); /** * Describes an Application instance. */ abstract protected function describeApplication(Application $application, array $options = []); } __halt_compiler();----SIGNATURE:----ji2JrrzsS3h+AmtsWfu0qeFKhHE1z/9AgW9jQAw1j9Z0XNBKSBWVT0P7zFhDWFUcGZ62ILqUaOCz0YIE6o+Sn9WhqsEnM5XmnQgzQCx2axjSrB814HDY56LVVpaB1ZcbzuTGRBujrj+FGm9hXZRw8vmxlbK8mTJGpTKX0SzS4JKZUDiXQEyceIDmVlLUZXGM3tA/FQjCS0/vcLfnb9x/s5n6fJPcR46IBRnF6C024se1ngKM3p5emjn9wS0s5QKb+mxHCCTPLIXyBDWxZQ0yc8rPrEMcEDwkIU318eIonM8VRiZPRGWitV4F50ZrUPzZIGR0PC7IdM0f7dKovW2xTMNXxQLZ0YONc5+U7jtlYHhRlQevu9eBVDKyTg5vVQKquL7dQHC4Q50DFACxKqOOKnNYlcpzYO+6UzeJsq6ttH9Xd6e+XLU8Gt2YtGAAa7XhUvtzeMaFWPQVvfJADIImKJcqVQIKpOxHbLtnd5Ou1m/D3k0C9zKlpoWWkGNzyrHAOP3oANezCwILPM4K4b+WFDyEDwgD8N1mL1iNZDCzmThQTIZKaVT9aCJwjSZTeloksMtYsy+xR2ZPB8CkU11H6WeIW+/TF2YgCcppV2rneFXFLrn5PoORYbI/T3KYmpIZm1bjbFmRw3lqRCZAolGDexUKK0D+tLOefCR+cYANDSc=----ATTACHMENT:----NzA3MDcxMzY1MjE1ODcgMzg3ODcxMTQwNTA1MjA1NiAyMTYxMzY5NzM5MTA1NDgy