| Total Complexity | 3 |
| Total Lines | 27 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 14 | class StrToLower extends AbstractRule |
||
| 15 | { |
||
| 16 | /** |
||
| 17 | * @inheritdoc |
||
| 18 | */ |
||
| 19 | 1 | public function apply(array $rowData, array &$transformedData, array $options = []): string |
|
| 20 | { |
||
| 21 | 1 | $value = $options['value']; |
|
| 22 | 1 | unset($options['value']); |
|
| 23 | |||
| 24 | 1 | return strtolower($this->ruleApplier->apply($rowData, $transformedData, $value, $options)); |
|
|
|
|||
| 25 | } |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @inheritdoc |
||
| 29 | */ |
||
| 30 | 1 | public function validate(array $options): void |
|
| 31 | { |
||
| 32 | 1 | $this->requireOption('value', $options); |
|
| 33 | 1 | } |
|
| 34 | |||
| 35 | /** |
||
| 36 | * @inheritdoc |
||
| 37 | */ |
||
| 38 | 1 | public function getRuleCode(): string |
|
| 41 | } |
||
| 42 | } |