| Total Complexity | 11 |
| Total Lines | 54 |
| Duplicated Lines | 0 % |
| Coverage | 92.31% |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 12 | class Engine implements EngineInterface |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var ConfigInterface |
||
| 16 | */ |
||
| 17 | protected $config; |
||
| 18 | |||
| 19 | 9 | public function __construct(ConfigInterface $config) |
|
| 20 | { |
||
| 21 | 9 | $this->config = $config; |
|
| 22 | 9 | } |
|
| 23 | |||
| 24 | 5 | public function extractFirstName(string $input, bool $strict = false): ?Entry |
|
| 27 | } |
||
| 28 | |||
| 29 | 4 | public function extractMiddleName(string $input, bool $strict = false): ?Entry |
|
| 30 | { |
||
| 31 | 4 | return $this->findValueByType($input, Type::TYPE_MIDDLE_NAME, $strict); |
|
| 32 | } |
||
| 33 | |||
| 34 | 9 | protected function findValueByType(string $input, string $type, bool $strict): ?Entry |
|
| 66 | } |
||
| 67 | } |
||
| 68 |