DeferredUpDownCounter
class DeferredUpDownCounter implements UpDownCounterInterface
| internal |
Keep a pre-fork up-down counter usable after a worker meter is bound.
Properties
| protected UpDownCounterInterface|null | $delegate |
Methods
__construct(string $name, string|null $unit, string|null $description, array $advisory)
Create a deferred up-down counter.
void
bind(MeterInterface $meter)
Bind this handle to an instrument from the given meter.
void
unbind()
Unbind this handle from its worker instrument.
void
add(mixed $amount, iterable $attributes = [], mixed $context = null)
Add a value to the current up-down counter.
bool
isEnabled()
Determine whether the current up-down counter is enabled.
Details
at line 23
__construct(string $name, string|null $unit, string|null $description, array $advisory)
Create a deferred up-down counter.
at line 34
void
bind(MeterInterface $meter)
Bind this handle to an instrument from the given meter.
at line 47
void
unbind()
Unbind this handle from its worker instrument.
at line 55
void
add(mixed $amount, iterable $attributes = [], mixed $context = null)
Add a value to the current up-down counter.
at line 64
bool
isEnabled()
Determine whether the current up-down counter is enabled.