| Index: components/metrics/single_value_histograms_provider.cc
|
| diff --git a/components/metrics/single_value_histograms_provider.cc b/components/metrics/single_value_histograms_provider.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..1dfcb58696b06e1f8eac3b0e31f276101ab72ea6
|
| --- /dev/null
|
| +++ b/components/metrics/single_value_histograms_provider.cc
|
| @@ -0,0 +1,40 @@
|
| +// 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.
|
| +
|
| +#include "components/metrics/single_value_histograms_provider.h"
|
| +
|
| +#include "components/metrics/single_value_counts_histogram.h"
|
| +#include "mojo/public/cpp/bindings/strong_binding.h"
|
| +
|
| +namespace metrics {
|
| +
|
| +// static
|
| +void SingleValueHistogramsProvider::Create(
|
| + mojom::SingleValueHistogramsProviderRequest request) {
|
| + // TODO(dalecurtis): Is strong binding what we want here? Seems like we'd
|
| + // prefer this is lazily created and available forever more to RPHI.
|
| + mojo::MakeStrongBinding(base::MakeUnique<SingleValueHistogramsProvider>(),
|
| + std::move(request));
|
| +}
|
| +
|
| +SingleValueHistogramsProvider::SingleValueHistogramsProvider() {
|
| + LOG(ERROR) << __func__;
|
| +}
|
| +
|
| +SingleValueHistogramsProvider::~SingleValueHistogramsProvider() {
|
| + LOG(ERROR) << __func__;
|
| +}
|
| +
|
| +void SingleValueHistogramsProvider::AcquireSingleValueCountsHistogram(
|
| + const std::string& name,
|
| + base::HistogramBase::Sample min,
|
| + base::HistogramBase::Sample max,
|
| + uint32_t bucket_count,
|
| + mojom::SingleValueCountsHistogramRequest request) {
|
| + mojo::MakeStrongBinding(base::MakeUnique<SingleValueCountsHistogram>(
|
| + name, min, max, bucket_count),
|
| + std::move(request));
|
| +}
|
| +
|
| +} // namespace metrics
|
|
|