DebugProfilerTarget
API reference › Yii3 Debug › Profiling › DebugProfilerTarget
Accumulates the profiler messages dispatched to targets in memory for the current request.
Yiisoft\Profiler\Profiler::flush() moves its messages out before dispatching them, so a flush performed while the
capture is still deferred would otherwise leave the Profiling panel empty.
Methods
Section titled “Methods”| Method | Description | Defined by |
|---|---|---|
export() | Accumulates the exported messages, so every flush of the request reaches the capture. | DebugProfilerTarget |
messages() | Returns the messages accumulated for the current request. | DebugProfilerTarget |
reset() | Clears the messages accumulated for the previous request. | DebugProfilerTarget |
Method details
Section titled “Method details”export()
Section titled “export() ”public function export(Yiisoft\Profiler\Message[] $messages): voidAccumulates the exported messages, so every flush of the request reaches the capture.
Parameters
| Parameter | Type | Description |
|---|---|---|
$messages | Yiisoft\ | Profiling messages exported by the profiler. |
messages()
Section titled “messages() ”public function messages(): list<Yiisoft\Profiler\Message>Returns the messages accumulated for the current request.
Returns
list<Yiisoft\Profiler\Message>: Messages accumulated in export order.
reset()
Section titled “reset() ”public function reset(): voidClears the messages accumulated for the previous request.