예제 #1
0
 /**
  * Converts the level of a loglevel to a displayable text
  * @param integer The level of the logger
  * @return string The level of the logger in text
  */
 protected final function levelToText($errorLevel)
 {
     $level = array();
     if (LoggerLevel::contains($errorLevel, LoggerLevel::LEVEL_INFO)) {
         $level[] = 'INFO';
     }
     if (LoggerLevel::contains($errorLevel, LoggerLevel::LEVEL_NOTICE)) {
         $level[] = 'NOTICE';
     }
     if (LoggerLevel::contains($errorLevel, LoggerLevel::LEVEL_EVENT)) {
         $level[] = 'EVENT';
     }
     if (LoggerLevel::contains($errorLevel, LoggerLevel::LEVEL_WARNING)) {
         $level[] = 'WARNING';
     }
     if (LoggerLevel::contains($errorLevel, LoggerLevel::LEVEL_FAULT)) {
         $level[] = 'FAULT';
     }
     return implode('|', $level);
 }