PHP Class Imdb\Logger

Inheritance: implements Psr\Log\LoggerInterface
Mostrar archivo Open project: tboothman/imdbphp

Protected Properties

Property Type Description
$enabled

Public Methods

Method Description
__construct ( $enabled = true )
alert ( string $message, array $context = [] ) : null Action must be taken immediately.
critical ( string $message, array $context = [] ) Critical conditions.
debug ( string $message, array $context = [] ) Detailed debug information.
emergency ( string $message, array $context = [] ) : null System is unusable.
error ( string $message, array $context = [] ) Runtime errors that do not require immediate action but should typically be logged and monitored.
info ( string $message, array $context = [] ) : null Interesting events.
log ( mixed $level, string $message, array $context = [] ) Logs with an arbitrary level.
notice ( string $message, array $context = [] ) Normal but significant events.
warning ( string $message, array $context = [] ) Exceptional occurrences that are not errors.

Method Details

__construct() public method

public __construct ( $enabled = true )

alert() public method

Example: Entire website down, database unavailable, etc. This should trigger the SMS alerts and wake you up.
public alert ( string $message, array $context = [] ) : null
$message string
$context array
return null

critical() public method

Example: Application component unavailable, unexpected exception.
public critical ( string $message, array $context = [] )
$message string
$context array

debug() public method

Detailed debug information.
public debug ( string $message, array $context = [] )
$message string
$context array

emergency() public method

System is unusable.
public emergency ( string $message, array $context = [] ) : null
$message string
$context array
return null

error() public method

Runtime errors that do not require immediate action but should typically be logged and monitored.
public error ( string $message, array $context = [] )
$message string
$context array

info() public method

Example: User logs in, SQL logs.
public info ( string $message, array $context = [] ) : null
$message string
$context array
return null

log() public method

Logs with an arbitrary level.
public log ( mixed $level, string $message, array $context = [] )
$level mixed
$message string
$context array

notice() public method

Normal but significant events.
public notice ( string $message, array $context = [] )
$message string
$context array

warning() public method

Example: Use of deprecated APIs, poor use of an API, undesirable things that are not necessarily wrong.
public warning ( string $message, array $context = [] )
$message string
$context array

Property Details

$enabled protected_oe property

protected $enabled