| Total Complexity | 3 |
| Total Lines | 26 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 13 | final class TranslateCommand extends Command |
||
| 14 | { |
||
| 15 | protected static $defaultName = 'translator/translate'; |
||
| 16 | protected static $defaultDescription = 'Translates a message'; |
||
| 17 | |||
| 18 | private TranslatorInterface $translator; |
||
| 19 | |||
| 20 | public function __construct(TranslatorInterface $translator) |
||
| 24 | } |
||
| 25 | |||
| 26 | protected function configure() |
||
| 27 | { |
||
| 28 | $this->addArgument('message', InputArgument::REQUIRED, 'Message that will be translated.'); |
||
| 29 | $this->addArgument('locale', InputArgument::OPTIONAL, 'Translation locale.'); |
||
| 30 | } |
||
| 31 | |||
| 32 | protected function execute(InputInterface $input, OutputInterface $output) |
||
| 39 | } |
||
| 40 | } |
||
| 41 |