Conditions | 3 |
Paths | 4 |
Total Lines | 17 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
21 | protected function generateIdentifyingMethods(PhpClass $class) { |
||
22 | if (!$class->hasMethod('getType')) { |
||
23 | $class->setMethod(PhpMethod::create('getType') |
||
24 | ->addParameter(PhpParameter::create('model')) |
||
25 | ->setBody($this->twig->render('getType.twig', [ |
||
26 | 'type' => '@TODO' |
||
27 | ])) |
||
28 | ); |
||
29 | } |
||
30 | |||
31 | if (!$class->hasMethod('getId')) { |
||
32 | $class->setMethod(PhpMethod::create('getId') |
||
33 | ->addParameter(PhpParameter::create('model')) |
||
34 | ->setBody($this->twig->render('getId.twig')) |
||
35 | ); |
||
36 | } |
||
37 | } |
||
38 | |||
39 | } |