Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
100.00% |
3 / 3 |
|
100.00% |
2 / 2 |
CRAP | |
100.00% |
1 / 1 |
| NullInteractor | |
100.00% |
3 / 3 |
|
100.00% |
2 / 2 |
4 | |
100.00% |
1 / 1 |
| supports | |
100.00% |
2 / 2 |
|
100.00% |
1 / 1 |
3 | |||
| interactWith | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| 1 | <?php |
| 2 | namespace Apie\Console\Helpers; |
| 3 | |
| 4 | use Apie\Core\Context\ApieContext; |
| 5 | use Apie\Core\Enums\ScalarType; |
| 6 | use Apie\Core\Metadata\MetadataInterface; |
| 7 | use Apie\Core\Metadata\ScalarMetadata; |
| 8 | use Apie\Core\Metadata\ValueObjectMetadata; |
| 9 | use Symfony\Component\Console\Helper\HelperSet; |
| 10 | use Symfony\Component\Console\Input\InputInterface; |
| 11 | use Symfony\Component\Console\Output\OutputInterface; |
| 12 | |
| 13 | final class NullInteractor implements InputInteractorInterface |
| 14 | { |
| 15 | public function supports(MetadataInterface $metadata): bool |
| 16 | { |
| 17 | return ($metadata instanceof ScalarMetadata || $metadata instanceof ValueObjectMetadata) |
| 18 | && $metadata->toScalarType() === ScalarType::NULLVALUE; |
| 19 | } |
| 20 | public function interactWith( |
| 21 | MetadataInterface $metadata, |
| 22 | HelperSet $helperSet, |
| 23 | InputInterface $input, |
| 24 | OutputInterface $output, |
| 25 | ApieContext $context |
| 26 | ): mixed { |
| 27 | return null; |
| 28 | } |
| 29 | } |