LogRecord
in package
Table of Contents
Constants
- NANOS_PER_SECOND = 1000000000
Properties
- $attributes : array<string|int, mixed>
- $body : mixed
- $context : ContextInterface|null
- $observedTimestamp : int|null
- $severityNumber : int
- $severityText : string|null
- $timestamp : int|null
Methods
- __construct() : mixed
- setAttribute() : self
- setAttributes() : self
- setBody() : self
- setContext() : self
- setObservedTimestamp() : self
- setSeverityNumber() : self
- setSeverityText() : self
- setTimestamp() : self
Constants
NANOS_PER_SECOND
public
mixed
NANOS_PER_SECOND
= 1000000000
Properties
$attributes
protected
array<string|int, mixed>
$attributes
= []
$body
protected
mixed
$body
= null
$context
protected
ContextInterface|null
$context
= null
$observedTimestamp
protected
int|null
$observedTimestamp
= null
$severityNumber
protected
int
$severityNumber
= 0
$severityText
protected
string|null
$severityText
= null
$timestamp
protected
int|null
$timestamp
= null
Methods
__construct()
public
__construct([mixed $body = null ]) : mixed
Parameters
- $body : mixed = null
setAttribute()
public
setAttribute(string $name, mixed $value) : self
Parameters
- $name : string
- $value : mixed
Return values
selfsetAttributes()
public
setAttributes(iterable<string|int, mixed> $attributes) : self
Parameters
- $attributes : iterable<string|int, mixed>
-
Additional information about the specific event occurrence.
Tags
Return values
selfsetBody()
public
setBody([mixed $body = null ]) : self
Parameters
- $body : mixed = null
-
The log record body
Return values
selfsetContext()
public
setContext([ContextInterface|null $context = null ]) : self
Parameters
- $context : ContextInterface|null = null
Return values
selfsetObservedTimestamp()
public
setObservedTimestamp([int|null $observedTimestamp = null ]) : self
Parameters
- $observedTimestamp : int|null = null
-
Time, in nanoseconds since the unix epoch, when the event was observed by the collection system.
Return values
selfsetSeverityNumber()
public
setSeverityNumber(Severity|int $severityNumber) : self
Parameters
- $severityNumber : Severity|int
Tags
Return values
selfsetSeverityText()
public
setSeverityText(string $severityText) : self
Parameters
- $severityText : string
-
Severity text, also known as log level
Tags
Return values
selfsetTimestamp()
public
setTimestamp(int $timestamp) : self
Parameters
- $timestamp : int
-
Timestamp, in nanoseconds since the unix epoch, when the event occurred.