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

Breadcrumb

  1. Drupal Core 11.1.x

LateBindingTracer.php

Namespace

OpenTelemetry\API\Trace

File

vendor/open-telemetry/api/Trace/LateBindingTracer.php

View source
<?php

declare (strict_types=1);
namespace OpenTelemetry\API\Trace;

use Closure;
class LateBindingTracer implements TracerInterface {
    private ?TracerInterface $tracer = null;
    
    /** @param Closure(): TracerInterface $factory */
    public function __construct(Closure $factory) {
    }
    public function spanBuilder(string $spanName) : SpanBuilderInterface {
        return ($this->tracer ??= ($this->factory)())
            ->spanBuilder($spanName);
    }
    public function isEnabled() : bool {
        return true;
    }

}

Classes

Title Deprecated Summary
LateBindingTracer

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal