Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | |
100.00% |
5 / 5 |
|
100.00% |
3 / 3 |
CRAP | |
100.00% |
1 / 1 |
PhpFunctionParameter | |
100.00% |
5 / 5 |
|
100.00% |
3 / 3 |
3 | |
100.00% |
1 / 1 |
__construct | |
100.00% |
2 / 2 |
|
100.00% |
1 / 1 |
1 | |||
setModel | |
100.00% |
2 / 2 |
|
100.00% |
1 / 1 |
1 | |||
getModel | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 |
1 | <?php |
2 | |
3 | declare(strict_types=1); |
4 | |
5 | namespace WsdlToPhp\PackageGenerator\File\Element; |
6 | |
7 | use WsdlToPhp\PackageGenerator\Model\AbstractModel; |
8 | use WsdlToPhp\PhpGenerator\Element\PhpFunctionParameter as PhpFunctionParameterBase; |
9 | |
10 | final class PhpFunctionParameter extends PhpFunctionParameterBase |
11 | { |
12 | protected ?AbstractModel $model; |
13 | |
14 | public function __construct(string $name, $value = null, $type = null, AbstractModel $model = null) |
15 | { |
16 | parent::__construct($name, $value, $type); |
17 | $this->model = $model; |
18 | } |
19 | |
20 | public function setModel(AbstractModel $model): self |
21 | { |
22 | $this->model = $model; |
23 | |
24 | return $this; |
25 | } |
26 | |
27 | public function getModel(): ?AbstractModel |
28 | { |
29 | return $this->model; |
30 | } |
31 | } |