/** * Save the content of the request for futur handle and/or backup * * @param content The content to save (mandatory) * @param headers The headers to save (optional) * @param type Values : raw | decrypted | payload (mandatory) * * @return String : The main filename */ protected function saveMessage($content, $headers, $type = 'raw') { $message = new MessageSent(); $message->setMessage($content); $message->setHeaders($headers); $message->setMessageType($type); $this->eventDispatcher->dispatch('messageSent', $message); }