lithium\analysis\logger\adapter\FirePhp::_format PHP Method

_format() protected method

Generates a string representation of the type and message, suitable for FirePHP.
protected _format ( string $type, string $message ) : array
$type string Represents the message priority.
$message string Contains the actual message to store.
return array Returns the encoded string representations of the priority and message, in the `'key'` and `'content'` keys, respectively.
    protected function _format($type, $message)
    {
        $key = 'X-Wf-1-1-1-' . $this->_counter++;
        $content = array(array('Type' => $this->_levels[$type]), $message);
        $content = json_encode($content);
        $content = strlen($content) . '|' . $content . '|';
        return compact('key', 'content');
    }