| Total Complexity | 5 |
| Total Lines | 32 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 14 | trait TLines |
||
| 15 | { |
||
| 16 | /** |
||
| 17 | * @param string $input |
||
| 18 | * @return array<int, string> |
||
| 19 | */ |
||
| 20 | 38 | public function explosion(string $input): array |
|
| 21 | { |
||
| 22 | 38 | return explode(IFile::SEPARATOR, $input); |
|
| 23 | } |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @param array<int, string|int|float> $input |
||
| 27 | * @return string |
||
| 28 | */ |
||
| 29 | 17 | public function implosion(array $input): string |
|
| 30 | { |
||
| 31 | 17 | return implode(IFile::SEPARATOR, $input + ['']); |
|
| 32 | } |
||
| 33 | |||
| 34 | /** |
||
| 35 | * @param string $input |
||
| 36 | * @return bool |
||
| 37 | */ |
||
| 38 | 35 | public function filterEmptyLines(string $input): bool |
|
| 39 | { |
||
| 40 | 35 | return !empty($input) && ('#' !== $input[0]); |
|
| 41 | } |
||
| 42 | |||
| 43 | 43 | public function stripChars(string $input): string |
|
| 46 | } |
||
| 47 | } |
||
| 48 |