Skip to content

Commit

Permalink
Mention use statements for classes (#1722)
Browse files Browse the repository at this point in the history
main, 11.5
  • Loading branch information
linawolf authored Feb 22, 2022
1 parent 4aa0f0a commit 9582635
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Documentation/ApiOverview/CommandControllers/Index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,10 @@ command API. This is explained in depth on the following Symfony Documentation p

Add an optional argument and an optional option to your command::


// use Symfony\Component\Console\Input\InputArgument;
// use Symfony\Component\Console\Input\InputOption;

/**
* Configure the command by defining the name, options and arguments
*/
Expand Down Expand Up @@ -169,6 +173,9 @@ which can be passed on the command line:
This argument can be retrieved with :php:`$input->getArgument()`, the options with
:php:`$input->getOption()`, for example::

// use Symfony\Component\Console\Input\InputInterface;
// use Symfony\Component\Console\Output\OutputInterface;

protected function execute(InputInterface $input, OutputInterface $output)
{
// ...
Expand Down

0 comments on commit 9582635

Please sign in to comment.