StderrLogger

PSR-3 Logger that sends to STDERR

class StderrLogger implements LoggerInterface
use LoggerTrait
Copyright
2016 Appertly
License
Apache-2.0

Constructors / Destructors

Public
ReturnsSignature and Description
void
__construct(mixed $level)

Create a new Logger

Instance Methods

Public
ReturnsSignature and Description
void
log(mixed $level, mixed $message, array<string,mixed> $context = [])

Logs with an arbitrary level.

Method Details

__construct

public function __construct(mixed $level)

Create a new Logger

Parameters
NameTypeDescription
$levelmixed

The log level to display

log

public function log(mixed $level, mixed $message, array<string,mixed> $context = [])

Logs with an arbitrary level.

Parameters
NameTypeDescription
$levelmixed

Log level

$message

String message

$contextarray<string,mixed>

Optional context