Class LoggerLevel

Description

Defines the minimum set of levels recognized by the system, that is OFF, FATAL, ERROR, WARN, INFO, DEBUG and ALL.

The LoggerLevel class may be subclassed to define a larger level set.

  • version: $Revision: 884719 $
  • since: 0.5

Located in /LoggerLevel.php (line 34)


	
			
Class Constant Summary
 ALL = -2147483647
 DEBUG = 10000
 ERROR = 40000
 FATAL = 50000
 INFO = 20000
 OFF = 2147483647
 WARN = 30000
Method Summary
static void toLevel (mixed $arg, [ $defaultLevel = null], LoggerLevel $default)
boolean equals (object $o)
integer getSyslogEquivalent ()
integer toInt ()
string toString ()
Methods
static getLevelAll (line 171)

Returns an All Level

  • access: public
static LoggerLevel getLevelAll ()
static getLevelDebug (line 159)

Returns a Debug Level

  • access: public
static LoggerLevel getLevelDebug ()
static getLevelError (line 123)

Returns an Error Level

  • access: public
static LoggerLevel getLevelError ()
static getLevelFatal (line 111)

Returns a Fatal Level

  • access: public
static LoggerLevel getLevelFatal ()
static getLevelInfo (line 147)

Returns an Info Level

  • access: public
static LoggerLevel getLevelInfo ()
static getLevelOff (line 99)

Returns an Off Level

  • access: public
static LoggerLevel getLevelOff ()
static getLevelWarn (line 135)

Returns a Warn Level

  • access: public
static LoggerLevel getLevelWarn ()
static toLevel (line 227)

Convert the string passed as argument to a level. If the conversion fails, then this method returns a DEBUG Level.

  • access: public
static void toLevel (mixed $arg, [ $defaultLevel = null], LoggerLevel $default)
equals (line 84)

Two priorities are equal if their level fields are equal.

  • access: public
boolean equals (object $o)
  • object $o
getSyslogEquivalent (line 183)

Return the syslog equivalent of this priority as an integer.

  • final:
  • access: public
integer getSyslogEquivalent ()
isGreaterOrEqual (line 198)

Returns true if this level has a higher or equal level than the level passed as argument, false otherwise.

You should think twice before overriding the default implementation of isGreaterOrEqual method.

  • access: public
boolean isGreaterOrEqual (LoggerLevel $r)
toInt (line 215)

Returns the integer representation of this level.

  • access: public
integer toInt ()
toString (line 207)

Returns the string representation of this priority.

  • final:
  • access: public
string toString ()
Class Constants
ALL = -2147483647 (line 42)
DEBUG = 10000 (line 41)
ERROR = 40000 (line 38)
FATAL = 50000 (line 37)
INFO = 20000 (line 40)
OFF = 2147483647 (line 36)
WARN = 30000 (line 39)

Documentation generated on Fri, 27 Nov 2009 07:44:50 +0100 by phpDocumentor 1.4.3