Neuron-PHP

Log extends Memory
in package

Singleton for cross-cutting log access.

Table of Contents

Properties

$_instance  : mixed
$channels  : array<string|int, mixed>
$logger  : ILogger|null

Methods

addChannel()  : void
addFilter()  : void
alert()  : void
channel()  : LogMux
critical()  : void
debug()  : void
emergency()  : void
error()  : void
getInstance()  : ISingleton|null
getRunLevel()  : RunLevel
info()  : void
initIfNeeded()  : void
Creates and initializes the core logger if needed.
instance()  : mixed
Gets the global object instance.
invalidate()  : void
Clears the current global object.
notice()  : void
serialize()  : void
Writes the object data to the storage medium.
setContext()  : void
setRunLevel()  : void
staticLog()  : void
warning()  : void

Properties

$_instance

public static mixed $_instance = []

$channels

public array<string|int, mixed> $channels = []

Methods

addChannel()

public static addChannel(string $name, ILogger $logger) : void
Parameters
$name : string
$logger : ILogger

addFilter()

public static addFilter(IFilter $filter) : void
Parameters
$filter : IFilter

alert()

public static alert(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

channel()

public static channel(string $name) : LogMux
Parameters
$name : string
Return values
LogMux

critical()

public static critical(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

debug()

public static debug(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

emergency()

public static emergency(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

error()

public static error(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

info()

public static info(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

initIfNeeded()

Creates and initializes the core logger if needed.

public initIfNeeded() : void

instance()

Gets the global object instance.

public static instance() : mixed

invalidate()

Clears the current global object.

public static invalidate() : void

notice()

public static notice(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

serialize()

Writes the object data to the storage medium.

public serialize() : void

setContext()

public static setContext(string $name, mixed $value) : void
Parameters
$name : string
$value : mixed

Can be string, array, or other scalar/object types

setRunLevel()

public static setRunLevel(int $level) : void
Parameters
$level : int

staticLog()

public static staticLog(string $text, RunLevel $level[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$level : RunLevel
$context : array<string|int, mixed> = []

warning()

public static warning(string $text[, array<string|int, mixed> $context = [] ]) : void
Parameters
$text : string
$context : array<string|int, mixed> = []

        
On this page

Search results