/** * @inheritDoc */ public function handle(EventInterface $event) { if ($event instanceof AfterRouteEvent) { $fff = self::fff(); self::dispatchEvent(new LogEvent(LoggerLevelEnum::INFO(), LoggerTemplate::LOGGER_MESSAGE_RESPONSE_INFO, ['verb' => $fff->get('VERB'), 'pattern' => $fff->get('PATTERN'), 'uri' => $fff->get('URI'), 'response' => ob_get_contents()])); } }
/** * @inheritDoc */ public function handle(EventInterface $event) { if ($event instanceof BeforeRouteEvent) { $fff = self::fff(); self::dispatchEvent(new LogEvent(LoggerLevelEnum::INFO(), LoggerTemplate::LOGGER_MESSAGE_REQUEST_INFO, ['verb' => $fff->get('VERB'), 'pattern' => $fff->get('PATTERN'), 'uri' => $fff->get('URI'), 'body' => Utility::instance()->convertUnicodeToUTF8($fff->get('BODY'))])); } }