SentryDistributionMetric class final

A metric that tracks the statistical distribution of a set of values.

See SentryMetricUnit for predefined unit constants.

Inheritance

Constructors

SentryDistributionMetric({required DateTime timestamp, required String name, required num value, required SentryId traceId, SpanId? spanId, String? unit, Map<String, SentryAttribute>? attributes})

Properties

attributes ↔ Map<String, SentryAttribute>
Custom key-value pairs attached to the metric.
getter/setter pairinherited
hashCode → int
The hash code for this object.
no setterinherited
name ↔ String
The metric name, typically using dot notation (e.g., 'app.memory_usage').
getter/setter pairinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
spanId ↔ SpanId?
The span ID of the active span when the metric was recorded.
getter/setter pairinherited
timestamp ↔ DateTime
The time when the metric was recorded.
getter/setter pairinherited
traceId ↔ SentryId
The trace ID from the current propagation context.
getter/setter pairinherited
type → String
The metric type identifier (e.g., 'counter', 'gauge', 'distribution').
finalinherited
unit ↔ String?
The unit of measurement (e.g., 'millisecond', 'byte').
getter/setter pairinherited
value ↔ num
The numeric value of the metric.
getter/setter pairinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited