1 // Copyright 2016 The Chromium Authors
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_METRICS_SAMPLING_METRICS_PROVIDER_H_
6 #define COMPONENTS_METRICS_SAMPLING_METRICS_PROVIDER_H_
8 #include "components/metrics/metrics_provider.h"
12 // Provides metrics related to sampling of metrics reporting clients. In
13 // particular, the rate at which clients are sampled.
14 class SamplingMetricsProvider : public MetricsProvider {
16 // |sampling_rate_per_mille| is the number of clients per 1000 that are in the
18 explicit SamplingMetricsProvider(int sampling_rate_per_mille);
19 ~SamplingMetricsProvider() override = default;
20 SamplingMetricsProvider(const SamplingMetricsProvider&) = delete;
21 SamplingMetricsProvider operator=(const SamplingMetricsProvider&) = delete;
25 void ProvideStabilityMetrics(
26 SystemProfileProto* system_profile_proto) override;
28 int sampling_rate_per_mille_;
31 } // namespace metrics
33 #endif // COMPONENTS_METRICS_SAMPLING_METRICS_PROVIDER_H_