summaryrefslogtreecommitdiff
path: root/vendor/opentracing/opentracing/src/OpenTracing/NoopScopeManager.php
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/opentracing/opentracing/src/OpenTracing/NoopScopeManager.php')
-rw-r--r--vendor/opentracing/opentracing/src/OpenTracing/NoopScopeManager.php24
1 files changed, 24 insertions, 0 deletions
diff --git a/vendor/opentracing/opentracing/src/OpenTracing/NoopScopeManager.php b/vendor/opentracing/opentracing/src/OpenTracing/NoopScopeManager.php
new file mode 100644
index 000000000..5576171a8
--- /dev/null
+++ b/vendor/opentracing/opentracing/src/OpenTracing/NoopScopeManager.php
@@ -0,0 +1,24 @@
+<?php
+
+declare(strict_types=1);
+
+namespace OpenTracing;
+
+final class NoopScopeManager implements ScopeManager
+{
+ /**
+ * {@inheritdoc}
+ */
+ public function activate(Span $span, bool $finishSpanOnClose = ScopeManager::DEFAULT_FINISH_SPAN_ON_CLOSE): Scope
+ {
+ return new NoopScope();
+ }
+
+ /**
+ * {@inheritdoc}
+ */
+ public function getActive(): ?Scope
+ {
+ return new NoopScope();
+ }
+}