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

Breadcrumb

  1. Drupal Core 11.1.x

NoopTracer.php

Namespace

OpenTelemetry\API\Trace

File

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

View source
<?php

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

use OpenTelemetry\Context\Context;
final class NoopTracer implements TracerInterface {
    private static ?self $instance = null;
    public static function getInstance() : self {
        if (null === self::$instance) {
            self::$instance = new self();
        }
        return self::$instance;
    }
    public function spanBuilder(string $spanName) : SpanBuilderInterface {
        return new NoopSpanBuilder(Context::storage());
    }
    public function isEnabled() : bool {
        return false;
    }

}

Classes

Title Deprecated Summary
NoopTracer

API Navigation

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