Configurator
in package
implements
ImplicitContextKeyedInterface
FinalYes
Configures the global (context scoped) instrumentation instances.
Tags
Table of Contents
Interfaces
- ImplicitContextKeyedInterface
- Represents a value that can be stored within {@see ContextInterface}.
Properties
- $eventLoggerProvider : EventLoggerProviderInterface|null
- $loggerProvider : LoggerProviderInterface|null
- $meterProvider : MeterProviderInterface|null
- $propagator : TextMapPropagatorInterface|null
- $tracerProvider : TracerProviderInterface|null
Methods
- activate() : ScopeInterface
- Adds `$this` to the {@see Context::getCurrent() current context} and makes the new {@see Context} the current context.
- create() : Configurator
- Creates a configurator that uses parent instances for not configured values.
- createNoop() : Configurator
- Creates a configurator that uses noop instances for not configured values.
- storeInContext() : ContextInterface
- Returns a new {@see ContextInterface} created by setting `$this` into the provided [@see ContextInterface}.
- withEventLoggerProvider() : Configurator
- withLoggerProvider() : Configurator
- withMeterProvider() : Configurator
- withPropagator() : Configurator
- withTracerProvider() : Configurator
- __construct() : mixed
Properties
$eventLoggerProvider
private
EventLoggerProviderInterface|null
$eventLoggerProvider
= null
$loggerProvider
private
LoggerProviderInterface|null
$loggerProvider
= null
$meterProvider
private
MeterProviderInterface|null
$meterProvider
= null
$propagator
private
TextMapPropagatorInterface|null
$propagator
= null
$tracerProvider
private
TracerProviderInterface|null
$tracerProvider
= null
Methods
activate()
Adds `$this` to the {@see Context::getCurrent() current context} and makes the new {@see Context} the current context.
public
activate() : ScopeInterface
ScopeInterface::detach() MUST be called to properly restore the previous context.
This method is equivalent to Context::getCurrent().with($value).activate();
.
Return values
ScopeInterfacecreate()
Creates a configurator that uses parent instances for not configured values.
public
static create() : Configurator
Return values
ConfiguratorcreateNoop()
Creates a configurator that uses noop instances for not configured values.
public
static createNoop() : Configurator
Return values
ConfiguratorstoreInContext()
Returns a new {@see ContextInterface} created by setting `$this` into the provided [@see ContextInterface}.
public
storeInContext([ContextInterface|null $context = null ]) : ContextInterface
Parameters
- $context : ContextInterface|null = null
Return values
ContextInterfacewithEventLoggerProvider()
public
withEventLoggerProvider(EventLoggerProviderInterface|null $eventLoggerProvider) : Configurator
Parameters
- $eventLoggerProvider : EventLoggerProviderInterface|null
Return values
ConfiguratorwithLoggerProvider()
public
withLoggerProvider(LoggerProviderInterface|null $loggerProvider) : Configurator
Parameters
- $loggerProvider : LoggerProviderInterface|null
Return values
ConfiguratorwithMeterProvider()
public
withMeterProvider(MeterProviderInterface|null $meterProvider) : Configurator
Parameters
- $meterProvider : MeterProviderInterface|null
Return values
ConfiguratorwithPropagator()
public
withPropagator(TextMapPropagatorInterface|null $propagator) : Configurator
Parameters
- $propagator : TextMapPropagatorInterface|null
Return values
ConfiguratorwithTracerProvider()
public
withTracerProvider(TracerProviderInterface|null $tracerProvider) : Configurator
Parameters
- $tracerProvider : TracerProviderInterface|null
Return values
Configurator__construct()
private
__construct() : mixed