$consoleInput = new \Symfony\Component\Console\Input\ArgvInput(); $myArgumentValue = $consoleInput->getParameterOption('--myArgument');
$consoleInput = new \Symfony\Component\Console\Input\ArgvInput(); $myOptionValue = $consoleInput->getParameterOption('-o', true);In this example, we retrieve the value of a required option named `o` that was passed in as part of the console command. Note that the second argument to `getParameterOption` is set to `true`, which indicates that the option is required. If the option is not present in the input, an exception will be thrown. Overall, the Symfony Console Component package library provides a powerful set of tools for building command-line applications in PHP. By leveraging tools like InputInterface, developers can create user-friendly command-line interfaces without having to worry about low-level details like parsing command line arguments.