Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(343)

Unified Diff: components/metrics/single_value_histograms_provider.h

Issue 2687583002: Add support for single sample metrics. (Closed)
Patch Set: Redesign! Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/metrics/single_value_histograms_provider.h
diff --git a/components/metrics/single_value_histograms_provider.h b/components/metrics/single_value_histograms_provider.h
new file mode 100644
index 0000000000000000000000000000000000000000..d733a75d69c1a5a87277304eeb0d009019b837e8
--- /dev/null
+++ b/components/metrics/single_value_histograms_provider.h
@@ -0,0 +1,35 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef COMPONENTS_METRICS_SINGLE_VALUE_HISTOGRAMS_PROVIDER_H_
+#define COMPONENTS_METRICS_SINGLE_VALUE_HISTOGRAMS_PROVIDER_H_
+
+#include "base/macros.h"
+#include "base/metrics/histogram_base.h"
+#include "components/metrics/public/interfaces/single_value_histograms.mojom.h"
+
+namespace metrics {
+
+class SingleValueHistogramsProvider
+ : public mojom::SingleValueHistogramsProvider {
+ public:
+ static void Create(mojom::SingleValueHistogramsProviderRequest request);
+
+ SingleValueHistogramsProvider();
+ ~SingleValueHistogramsProvider() override;
+
+ private:
+ void AcquireSingleValueCountsHistogram(
+ const std::string& name,
+ base::HistogramBase::Sample min,
+ base::HistogramBase::Sample max,
+ uint32_t bucket_count,
+ mojom::SingleValueCountsHistogramRequest request) override;
+
+ DISALLOW_COPY_AND_ASSIGN(SingleValueHistogramsProvider);
+};
+
+} // namespace metrics
+
+#endif // COMPONENTS_METRICS_SINGLE_VALUE_HISTOGRAMS_PROVIDER_H_

Powered by Google App Engine
This is Rietveld 408576698