| Conditions | 3 |
| Paths | 4 |
| Total Lines | 16 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 27 | public function __invoke( |
||
| 28 | ContainerInterface $container, |
||
| 29 | string $requestedName, |
||
| 30 | array $options = null |
||
| 31 | ): MemoryPeakUsageProcessor { |
||
| 32 | $options = $options ?? $this->getServiceOptions($container, $requestedName); |
||
| 33 | |||
| 34 | $realUsage = isset($options['real_usage']) |
||
| 35 | ? (bool)$options['real_usage'] |
||
| 36 | : true; |
||
| 37 | |||
| 38 | $useFormatting = isset($options['use_formatting']) |
||
| 39 | ? (bool)$options['use_formatting'] |
||
| 40 | : true; |
||
| 41 | |||
| 42 | return new MemoryPeakUsageProcessor($realUsage, $useFormatting); |
||
| 43 | } |
||
| 45 |