Exemplo n.º 1
0
 function __construct($name)
 {
     self::$isLog4phpUsed = class_exists('Nmmlm_Log_Logger', false);
     if (self::$isLog4phpUsed) {
         $this->loggerLog4php = Nmmlm_Log_Logger::getLogger($name);
     } else {
         $this->name = is_object($name) ? get_class($name) : (string) $name;
     }
 }
Exemplo n.º 2
0
 public function test_all()
 {
     $log = Praxigento_Quickorder_Model_Logger::getLogger($this);
     $log->trace('trace');
     $log->debug('debug');
     $log->info('info');
     $log->warn('warn');
     $log->error('error');
     $log->fatal('fatal');
     $log->trace('trace', new Exception('test trace error'));
     $log->debug('debug', new Exception('test debug error'));
     $log->info('info', new Exception('test info error'));
     $log->warn('warn', new Exception('test warn error'));
     $log->error('error', new Exception('test error error'));
     $log->fatal('fatal', new Exception('test fatal error'));
 }