| 1 |
<?php |
| 2 |
namespace Wikimedia\Telemetry; |
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
class NoopSpan implements SpanInterface { |
| 11 |
private SpanContext $context; |
| 12 |
|
| 13 |
public function __construct( SpanContext $context ) { |
| 14 |
$this->context = $context; |
| 15 |
} |
| 16 |
|
| 17 |
|
| 18 |
public function getContext(): SpanContext { |
| 19 |
return $this->context; |
| 20 |
} |
| 21 |
|
| 22 |
|
| 23 |
public function setAttributes( array $attributes ): SpanInterface { |
| 24 |
return $this; |
| 25 |
} |
| 26 |
|
| 27 |
|
| 28 |
public function setSpanKind( int $spanKind ): SpanInterface { |
| 29 |
return $this; |
| 30 |
} |
| 31 |
|
| 32 |
|
| 33 |
public function start( ?int $epochNanos = null ): SpanInterface { |
| 34 |
return $this; |
| 35 |
} |
| 36 |
|
| 37 |
|
| 38 |
public function end( ?int $epochNanos = null ): void { |
| 39 |
|
| 40 |
} |
| 41 |
|
| 42 |
|
| 43 |
public function activate(): void { |
| 44 |
|
| 45 |
} |
| 46 |
|
| 47 |
|
| 48 |
public function deactivate(): void { |
| 49 |
|
| 50 |
} |
| 51 |
} |