Skip to content
PHP Ecosystem
Explore

EventCapture

API reference › Debug Core › Panel › Event › EventCapture

final classPHPForge\Debug\Panel\Event\EventCapture
Sourcesrc/Panel/Event/EventCapture.php

Bounds and sanitizes explicitly selected event diagnostics without inspecting arbitrary objects.

MethodDescriptionDefined by
context() staticBounds and sanitizes the adapter-selected context fields.EventCapture
trace() staticBounds and sanitizes the source frames observed when an event fired.EventCapture
public static function context(array<string, string> $fields): array<string, string>

Bounds and sanitizes the adapter-selected context fields.

Parameters

ParameterTypeDescription
$fieldsarray<string, string>Adapter-selected fields only.

Returns

array<string, string>: At most sixteen sanitized fields, with sensitive values replaced by [redacted].

public static function trace(list<array<string, mixed>> $frames, int $limit, list<string> $skipFiles = []): list<string>

Bounds and sanitizes the source frames observed when an event fired.

Parameters

ParameterTypeDescription
$frameslist<array<string, mixed>>Backtrace acquired with DEBUG_BACKTRACE_IGNORE_ARGS.
$limitintMaximum frames; hard-limited to sixteen.
$skipFileslist<string>Adapter instrumentation files to omit.

Returns

list<string>: Sanitized file:line frames in call order.