blob: feef096b40aa9bfd7010e53ea1552166f37a6135 [file] [log] [blame]
Weilun Shi37970332020-01-17 00:39:511// Copyright 2020 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef COMPONENTS_METRICS_ENTROPY_STATE_PROVIDER_H_
6#define COMPONENTS_METRICS_ENTROPY_STATE_PROVIDER_H_
7
8#include "components/metrics/entropy_state.h"
9#include "components/metrics/metrics_provider.h"
10
11class PrefService;
12
13namespace metrics {
14
15// EntropyStateProvider adds information about low entropy sources in the system
16// profile. This includes |low_entropy_source| and |old_low_entropy_source|.
17class EntropyStateProvider : public MetricsProvider {
18 public:
19 explicit EntropyStateProvider(PrefService* local_state);
20 ~EntropyStateProvider() override;
21
22 EntropyStateProvider(const EntropyStateProvider&) = delete;
23 EntropyStateProvider& operator=(const EntropyStateProvider&) = delete;
24
25 void ProvideSystemProfileMetrics(
26 SystemProfileProto* system_profile_proto) override;
27
28 private:
29 EntropyState entropy_state_;
30};
31
32} // namespace metrics
33
34#endif // COMPONENTS_METRICS_ENTROPY_STATE_PROVIDER_H_