23 private static $initialized =
false;
25 private $log4phpLogger =
null;
31 if (!self::$initialized) {
32 Logger::configure($configFile);
33 self::$initialized =
true;
35 $name = str_replace(
'\\',
'.', $name);
42 public function trace($message) {
43 $this->log4phpLogger->trace($message);
49 public function debug($message) {
50 $this->log4phpLogger->debug($message);
56 public function info($message) {
57 $this->log4phpLogger->info($message);
63 public function warn($message) {
64 $this->log4phpLogger->warn($message);
70 public function error($message) {
71 $this->log4phpLogger->error($message);
77 public function fatal($message) {
78 $this->log4phpLogger->fatal($message);
85 return $this->log4phpLogger->isDebugEnabled();
92 return $this->log4phpLogger->isInfoEnabled();
99 return $this->log4phpLogger->isWarnEnabled();
106 return $this->log4phpLogger->isErrorEnabled();
113 return $this->log4phpLogger->isFatalEnabled();
__construct($name, $configFile='')
Constructor.
Log4phpLogger is a wrapper for the log4php library.
static getLogger($name)
Get a Logger instance by name.
AbstractLogger is the abstract base class for Logger implementations.
Interface for logger implementations.