Total Complexity | 3 |
Total Lines | 33 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
16 | class Constant extends AbstractRule |
||
17 | { |
||
18 | |||
19 | /** |
||
20 | * Apply a certain rule and returns the result. |
||
21 | * |
||
22 | * @param array $rowData Data that is being trasformed. |
||
23 | * @param array $transformedData Transformed data at the current stage |
||
24 | 1 | * @param array $options Options to be used by the rule. |
|
25 | * |
||
26 | 1 | * @return string|null |
|
27 | */ |
||
28 | public function apply(array $rowData, array &$transformedData, array $options = []) |
||
31 | } |
||
32 | 1 | ||
33 | /** |
||
34 | 1 | * @inheritdoc |
|
35 | 1 | */ |
|
36 | public function validate($options): void |
||
37 | { |
||
38 | $this->requireOption('value', $options); |
||
39 | } |
||
40 | |||
41 | /** |
||
42 | 1 | * Get unique code that needs to be used to apply this rule. |
|
43 | * |
||
44 | 1 | * @return string |
|
45 | */ |
||
46 | public function getRuleCode(): string |
||
49 | } |
||
50 | } |