Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ExtensionHookManager.php

function ExtensionHookManager::hook

@phan-suppress PhanUndeclaredFunction

Overrides HookManagerInterface::hook

File

vendor/open-telemetry/api/Instrumentation/AutoInstrumentation/ExtensionHookManager.php, line 21

Class

ExtensionHookManager
@phan-file-suppress PhanUndeclaredClassAttribute

Namespace

OpenTelemetry\API\Instrumentation\AutoInstrumentation

Code

public function hook(?string $class, string $function, ?Closure $preHook = null, ?Closure $postHook = null) : void {
    assert(extension_loaded('opentelemetry'));
    
    /** @noinspection PhpFullyQualifiedNameUsageInspection */
    \OpenTelemetry\Instrumentation\hook($class, $function, $this->bindHookScope($preHook), $this->bindHookScope($postHook));
}
RSS feed
Powered by Drupal