| Total Complexity | 5 |
| Total Lines | 39 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 10 | abstract class BaseProcess implements Process |
||
| 11 | { |
||
| 12 | /** @var string */ |
||
| 13 | protected $locale; |
||
| 14 | |||
| 15 | /** @var bool */ |
||
| 16 | protected $force; |
||
| 17 | |||
| 18 | protected $result = []; |
||
| 19 | |||
| 20 | public function locale(string $locale): self |
||
| 21 | { |
||
| 22 | $this->locale = $locale; |
||
| 23 | |||
| 24 | return $this; |
||
| 25 | } |
||
| 26 | |||
| 27 | public function force(bool $force = false): self |
||
| 28 | { |
||
| 29 | $this->force = $force; |
||
| 30 | |||
| 31 | return $this; |
||
| 32 | } |
||
| 33 | |||
| 34 | public function result(): array |
||
| 35 | { |
||
| 36 | return $this->result; |
||
| 37 | } |
||
| 38 | |||
| 39 | protected function push(string $filename, string $status): void |
||
| 40 | { |
||
| 41 | $locale = $this->locale; |
||
| 42 | |||
| 43 | $this->result[] = compact('locale', 'filename', 'status'); |
||
| 44 | } |
||
| 45 | |||
| 46 | protected function checkExists(string $path): void |
||
| 49 | } |
||
| 50 | } |
||
| 51 |