| Conditions | 2 |
| Paths | 2 |
| Total Lines | 24 |
| Code Lines | 19 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 17 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 10 | 4 | public function process(CallerData $data): string |
|
| 11 | { |
||
| 12 | 4 | $function = $data->getFunction(); |
|
| 13 | $lineAndFile = |
||
| 14 | 4 | sprintf( |
|
| 15 | 4 | '[%s:"%s"]', |
|
| 16 | 4 | $data->getLine(), |
|
| 17 | 4 | $data->getFile() |
|
| 18 | ); |
||
| 19 | 4 | if (null !== $class = $data->getClass()) { |
|
| 20 | return |
||
| 21 | 3 | sprintf( |
|
| 22 | 3 | '%s%s%s %s', |
|
| 23 | 3 | $class, |
|
| 24 | 3 | $data->getType(), |
|
| 25 | 3 | $function, |
|
| 26 | 3 | $lineAndFile |
|
| 27 | ); |
||
| 28 | } |
||
| 29 | return |
||
| 30 | 1 | sprintf( |
|
| 31 | 1 | '%s %s', |
|
| 32 | 1 | $function, |
|
| 33 | 1 | $lineAndFile |
|
| 34 | ); |
||
| 37 |