Show / Hide Table of Contents

Interface IServerTimingMetricFilter<TContext>

A filter that can inspect and modify the metrics which are to be delivered in a response to current request.

Namespace: Lib.ServerTiming.Filters
Assembly: Lib.ServerTiming.Abstractions.dll
Syntax
public interface IServerTimingMetricFilter<TContext>
Type Parameters
Name Description
TContext

The type of context required by filter.

Methods

OnServerTimingHeaderPreparation(TContext, ICollection<ServerTimingMetric>)

Inspects and modifies the collection of metrics for current request. If no more metrics remain in the collection after, the Server-Timing header will not be sent.

Declaration
bool OnServerTimingHeaderPreparation(TContext context, ICollection<ServerTimingMetric> metrics)
Parameters
Type Name Description
TContext context

The context for the current request.

System.Collections.Generic.ICollection<ServerTimingMetric> metrics

The collection of metrics for current request.

Returns
Type Description
System.Boolean

True if subsequent filters are allowed to run, otherwise false.

Back to top Copyright © 2017 - 2023 Tomasz Pęczek