diff --git a/library/log4php/LoggerLayout.php b/library/log4php/LoggerLayout.php new file mode 100644 --- /dev/null +++ b/library/log4php/LoggerLayout.php @@ -0,0 +1,74 @@ +getRenderedMessage(); + } + + /** + * Returns the content type output by this layout. + * @return string + */ + public function getContentType() { + return "text/plain"; + } + + /** + * Returns the footer for the layout format. + * @return string + */ + public function getFooter() { + return null; + } + + /** + * Returns the header for the layout format. + * @return string + */ + public function getHeader() { + return null; + } + + /** Triggers a warning for this layout with the given message. */ + protected function warn($message) { + trigger_error("log4php: [" . get_class($this) . "]: $message", E_USER_WARNING); + } +}