-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathopentelemetry.stub.php
More file actions
23 lines (20 loc) · 925 Bytes
/
opentelemetry.stub.php
File metadata and controls
23 lines (20 loc) · 925 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<?php
/** @generate-class-entries */
namespace OpenTelemetry\Instrumentation;
/**
* @param string|null $class The (optional) hooked function's class. Null for a global/built-in function.
* @param string $function The hooked function's name.
* @param \Closure|null $pre function($class, array $params, ?string $class, string $function, ?string $filename, ?int $lineno, ?array $span_args, ?array $span_attributes): $params
* You may optionally return modified parameters.
* @param \Closure|null $post function($class, array $params, $returnValue, ?Throwable $exception): $returnValue
* You may optionally return modified return value.
* @return bool Whether the observer was successfully added
*
* @see https://github.com/open-telemetry/opentelemetry-php-instrumentation
*/
function hook(
string|null $class,
string $function,
?\Closure $pre = null,
?\Closure $post = null,
): bool {}