| Total Complexity | 3 |
| Total Lines | 23 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 11 | #[Attribute(Attribute::TARGET_PARAMETER), NamedArgumentConstructor] |
||
| 12 | final class Argument extends AbstractDefinition |
||
| 13 | { |
||
| 14 | public readonly mixed $defaultValue; |
||
| 15 | |||
| 16 | 3 | public function __construct( |
|
| 17 | ?string $name = null, |
||
| 18 | ?string $description = null, |
||
| 19 | public readonly ?string $type = null, |
||
| 20 | public readonly ?int $mode = null, |
||
| 21 | public readonly ?string $deprecationReason = null, |
||
| 22 | mixed $defaultValue = null, |
||
| 23 | ) { |
||
| 24 | 3 | parent::__construct($name, $description); |
|
| 25 | |||
| 26 | 3 | if (func_num_args() >= 6) { |
|
| 27 | 2 | $this->defaultValue = $defaultValue; |
|
|
|
|||
| 28 | } |
||
| 29 | } |
||
| 30 | |||
| 31 | 3 | public function hasDefaultValue(): bool |
|
| 34 | } |
||
| 35 | } |
||
| 36 |