Total Complexity | 4 |
Total Lines | 25 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php declare(strict_types=1); |
||
15 | final class UseCaseBuilder extends AbstractBuilder |
||
16 | 7 | { |
|
17 | public function __construct(SchemaInterface $schema, string $action) |
||
18 | { |
||
19 | 7 | $entity = $this->getInflector()->entity($schema->name()); |
|
20 | $action = $this->getInflector()->pascalAction($action); |
||
21 | 7 | $item = $this->getInflector()->item($schema->name()); |
|
22 | $pkName = $this->getInflector()->camelProperty($schema->pkName()); |
||
23 | |||
24 | parent::__construct(\compact('entity', 'action', 'item', 'pkName')); |
||
25 | } |
||
26 | |||
27 | public function build(): string |
||
28 | { |
||
29 | return \rtrim(parent::build()); |
||
30 | } |
||
31 | |||
32 | protected function getFileTemplate(): string |
||
35 | } |
||
36 | |||
37 | protected function getPathTemplate(): string |
||
42 |