Nextcloud PHP API (master)

ILogger

Interface ILogger

use the PSR-3 logger \Psr\Log\LoggerInterface

Tags
since
7.0.0

This logger interface follows the design guidelines of PSR-3 https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md#3-psrlogloggerinterface

Table of Contents

Constants

DEBUG  = 0
ERROR  = 3
FATAL  = 4
INFO  = 1
WARN  = 2

Methods

alert()  : null
Action must be taken immediately.
critical()  : null
Critical conditions.
debug()  : null
Detailed debug information.
emergency()  : null
System is unusable.
error()  : null
Runtime errors that do not require immediate action but should typically be logged and monitored.
info()  : null
Interesting events.
log()  : mixed
Logs with an arbitrary level.
logException()  : void
Logs an exception very detailed An additional message can we written to the log by adding it to the context.
notice()  : null
Normal but significant events.
warning()  : null
Exceptional occurrences that are not errors.

Constants

DEBUG

public mixed DEBUG = 0
Tags
since
14.0.0

ERROR

public mixed ERROR = 3
Tags
since
14.0.0

FATAL

public mixed FATAL = 4
Tags
since
14.0.0

INFO

public mixed INFO = 1
Tags
since
14.0.0

WARN

public mixed WARN = 2
Tags
since
14.0.0

Methods

alert()

Action must be taken immediately.

public alert(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::alert

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

critical()

Critical conditions.

public critical(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::critical

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

debug()

Detailed debug information.

public debug(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::debug

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

emergency()

System is unusable.

public emergency(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::emergency

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

error()

Runtime errors that do not require immediate action but should typically be logged and monitored.

public error(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::error

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

info()

Interesting events.

public info(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::info

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

log()

Logs with an arbitrary level.

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

use \Psr\Log\LoggerInterface::log

Parameters
$level : int
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0

logException()

Logs an exception very detailed An additional message can we written to the log by adding it to the context.

public logException(Exception|Throwable $exception[, array<string|int, mixed> $context = [] ]) : void

use the exception entry in the context of any method in \Psr\Log\LoggerInterface

$logger->logException($ex, [ 'message' => 'Exception during background job execution' ]);
Parameters
$exception : Exception|Throwable
$context : array<string|int, mixed> = []
Tags
since
8.2.0

notice()

Normal but significant events.

public notice(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::notice

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

warning()

Exceptional occurrences that are not errors.

public warning(string $message[, array<string|int, mixed> $context = [] ]) : null

use \Psr\Log\LoggerInterface::warning

Parameters
$message : string
$context : array<string|int, mixed> = []
Tags
since
7.0.0
Return values
null

        
On this page

Search results