Total Complexity | 6 |
Total Lines | 52 |
Duplicated Lines | 0 % |
Coverage | 88.24% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
11 | class BaselineCommentsCommand extends Command |
||
12 | { |
||
13 | |||
14 | protected static $defaultName = 'app:comments:baseline'; |
||
15 | |||
16 | private ?\DateTime $from = null; |
||
17 | |||
18 | /** |
||
19 | * @param CommentsApiInterface $commentsApi |
||
20 | */ |
||
21 | 1 | public function __construct( |
|
22 | private CommentsApiInterface $commentsApi |
||
23 | ) |
||
24 | { |
||
25 | 1 | parent::__construct(); |
|
26 | 1 | } |
|
27 | |||
28 | |||
29 | 1 | protected function configure(): void |
|
30 | { |
||
31 | 1 | $this->addArgument('from', InputArgument::OPTIONAL, 'from'); |
|
32 | 1 | } |
|
33 | |||
34 | /** |
||
35 | * @param InputInterface $input |
||
36 | * @param OutputInterface $output |
||
37 | * @return int |
||
38 | */ |
||
39 | 1 | protected function execute(InputInterface $input, OutputInterface $output): int |
|
54 | |||
55 | } |
||
56 | |||
57 | /** |
||
58 | * @return \DateTime|null |
||
59 | */ |
||
60 | 1 | public function getFrom(): ?\DateTime |
|
68 | } |