| Total Complexity | 7 |
| Total Lines | 57 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 4 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php declare(strict_types=1); |
||
| 10 | class ProfilerReport extends AbstractReport implements Strings |
||
| 11 | { |
||
| 12 | /** @var array */ |
||
| 13 | private $reports = []; |
||
| 14 | |||
| 15 | /** |
||
| 16 | * @return array |
||
| 17 | */ |
||
| 18 | 2 | public function getReports(): array |
|
| 19 | { |
||
| 20 | 2 | return $this->reports; |
|
| 21 | } |
||
| 22 | |||
| 23 | /** {@inheritDoc} |
||
| 24 | * @throws \Exception |
||
| 25 | */ |
||
| 26 | 1 | protected function extractDataFrom(AbstractReportable $reportable = null): void |
|
| 34 | 10 | } |
|
| 35 | 10 | } |
|
| 36 | } |
||
| 37 | 10 | ||
| 38 | 10 | // public function buildOn(ReportableInterface $profiler): ReportInterface |
|
| 39 | // { |
||
| 40 | // if ($profiler instanceof Profiler) { |
||
| 41 | 1 | // foreach ($profiler->getCounters() as $counter) { |
|
| 42 | // $this->reports[self::COUNTERS][$counter->getName()] = $counter->report(); |
||
| 43 | 10 | // } |
|
| 44 | // foreach ($profiler->getTimers() as $timer) { |
||
| 45 | // $this->reports[self::TIMERS][$timer->getName()] = $timer->report(); |
||
| 46 | // } |
||
| 47 | // } else { |
||
| 48 | // $this->wrongReportable(Profiler::class, $profiler); |
||
| 49 | 3 | // } |
|
| 50 | // return $this; |
||
| 51 | 3 | // } |
|
| 52 | // |
||
| 53 | /** |
||
| 54 | * @return array |
||
| 55 | */ |
||
| 56 | public function getCountersReports(): array |
||
| 59 | 3 | } |
|
| 60 | |||
| 61 | /** |
||
| 62 | * @return array |
||
| 63 | */ |
||
| 64 | public function getTimersReports(): array |
||
| 69 |