BeforeSendMetricCallback typedef

BeforeSendMetricCallback = FutureOr<SentryMetric?> Function(SentryMetric metric, Hint hint)

This function is called right before a metric is about to be emitted. Can return a modified metric or null to drop the metric.

Implementation

typedef BeforeSendMetricCallback =
    FutureOr<SentryMetric?> Function(SentryMetric metric, Hint hint);