_format = $format; } /** * Formats data into a single line to be written by the writer. * * @param array $event event data * @return string formatted line to write to the log */ public function format($event) { $output = $this->_format; foreach ($event as $name => $value) { $output = str_replace("%$name%", $value, $output); } return $output; } }