EventHandler
class EventHandler
Traits
Constants
| private CONTEXT_RESPONSE_SPANS_KEY |
|
| CONTEXT_TRANSACTION_SPANS_KEY |
|
| private CONTEXT_CLEANUP_REGISTERED_KEY |
|
Properties
| static protected array<class-string, string> | $eventHandlerMap | Map event handlers to events. |
Methods
Resolve the code location of the first application frame of the event.
Resolve the code location of the event as a "file:line" string.
Create a new tracing event handler instance.
Pass through the event and capture any errors.
Handle a database transaction beginning event.
Handle a database transaction committed event.
Handle a database transaction rolled back event.
Details
in
ResolvesEventOrigin at line 15
protected Container
container()
Retrieve the application container.
in
ResolvesEventOrigin at line 25
protected array|null
resolveEventOrigin(array|null $backtrace = null)
Resolve the code location of the first application frame of the event.
in
ResolvesEventOrigin at line 52
protected string|null
resolveEventOriginAsString()
Resolve the code location of the event as a "file:line" string.
at line 72
__construct(array $config)
Create a new tracing event handler instance.
at line 91
void
subscribe(Dispatcher $dispatcher)
Attach all event handlers.
at line 105
void
__call(string $method, array $arguments)
Pass through the event and capture any errors.
at line 127
protected void
routeMatchedHandler(RouteMatched $match)
Handle a route matched event.
at line 144
protected void
queryExecutedHandler(QueryExecuted $query)
Handle a query executed event.
at line 206
protected void
responsePreparedHandler(ResponsePrepared $event)
Handle a response prepared event.
at line 218
protected void
responsePreparingHandler(PreparingResponse $event)
Handle a response preparing event.
at line 246
protected void
transactionBeginningHandler(TransactionBeginning $event)
Handle a database transaction beginning event.
at line 272
protected void
transactionCommittedHandler(TransactionCommitted $event)
Handle a database transaction committed event.
at line 285
protected void
transactionRolledBackHandler(TransactionRolledBack $event)
Handle a database transaction rolled back event.