Total Complexity | 8 |
Total Lines | 55 |
Duplicated Lines | 0 % |
Coverage | 39.13% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
10 | class FieldConfigurationEvent extends Event |
||
11 | { |
||
12 | private string $fieldName; |
||
13 | private ?string $type; |
||
14 | private ?FieldInterface $field; |
||
15 | private array $options; |
||
16 | private array $context; |
||
17 | |||
18 | 7 | public function __construct( |
|
19 | string $fieldName, |
||
20 | string $type = null, |
||
21 | array $options = [], |
||
22 | array $context = [], |
||
23 | FieldInterface $field = null |
||
24 | ) { |
||
25 | 7 | $this->fieldName = $fieldName; |
|
26 | 7 | $this->type = $type; |
|
27 | 7 | $this->field = $field; |
|
28 | 7 | $this->options = $options; |
|
29 | 7 | $this->context = $context; |
|
30 | 7 | } |
|
31 | |||
32 | public function setType(string $type): void |
||
33 | { |
||
34 | $this->type = $type; |
||
35 | } |
||
36 | |||
37 | public function getType(): ?string |
||
38 | { |
||
39 | return $this->type; |
||
40 | } |
||
41 | |||
42 | public function setOptions(array $options): void |
||
43 | { |
||
44 | $this->options = $options; |
||
45 | } |
||
46 | |||
47 | 7 | public function getOptions(): array |
|
50 | } |
||
51 | |||
52 | public function getFieldName(): string |
||
55 | } |
||
56 | |||
57 | public function getField(): ?FieldInterface |
||
58 | { |
||
59 | return $this->field; |
||
60 | } |
||
61 | |||
62 | public function getContext(): array |
||
65 | } |
||
66 | } |
||
67 |