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

Side by Side Diff: chrome/common/metrics/metrics_service_base.h

Issue 10829466: SampleSet -> HistogramSamples (will be reused by SparseHistogram) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_COMMON_METRICS_METRICS_SERVICE_BASE_H_ 5 #ifndef CHROME_COMMON_METRICS_METRICS_SERVICE_BASE_H_
6 #define CHROME_COMMON_METRICS_METRICS_SERVICE_BASE_H_ 6 #define CHROME_COMMON_METRICS_METRICS_SERVICE_BASE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/metrics/histogram_flattener.h" 10 #include "base/metrics/histogram_flattener.h"
11 #include "base/metrics/histogram_snapshot_manager.h" 11 #include "base/metrics/histogram_snapshot_manager.h"
12 #include "chrome/common/metrics/metrics_log_manager.h" 12 #include "chrome/common/metrics/metrics_log_manager.h"
13 13
14 // This class provides base functionality for logging metrics data. 14 // This class provides base functionality for logging metrics data.
15 // TODO(ananta): Factor out more common code from chrome and chrome frame 15 // TODO(ananta): Factor out more common code from chrome and chrome frame
16 // metrics service into this class. 16 // metrics service into this class.
17 class MetricsServiceBase : public base::HistogramFlattener { 17 class MetricsServiceBase : public base::HistogramFlattener {
18 public: 18 public:
19 // HistogramFlattener interface (override) methods. 19 // HistogramFlattener interface (override) methods.
20 virtual void RecordDelta(const base::Histogram& histogram, 20 virtual void RecordDelta(const base::Histogram& histogram,
21 const base::Histogram::SampleSet& snapshot) OVERRIDE; 21 const base::HistogramSamples& snapshot) OVERRIDE;
22 virtual void InconsistencyDetected( 22 virtual void InconsistencyDetected(
23 base::Histogram::Inconsistencies problem) OVERRIDE; 23 base::Histogram::Inconsistencies problem) OVERRIDE;
24 virtual void UniqueInconsistencyDetected( 24 virtual void UniqueInconsistencyDetected(
25 base::Histogram::Inconsistencies problem) OVERRIDE; 25 base::Histogram::Inconsistencies problem) OVERRIDE;
26 virtual void InconsistencyDetectedInLoggedCount(int amount) OVERRIDE; 26 virtual void InconsistencyDetectedInLoggedCount(int amount) OVERRIDE;
27 27
28 protected: 28 protected:
29 MetricsServiceBase(); 29 MetricsServiceBase();
30 virtual ~MetricsServiceBase(); 30 virtual ~MetricsServiceBase();
31 31
(...skipping 13 matching lines...) Expand all
45 MetricsLogManager log_manager_; 45 MetricsLogManager log_manager_;
46 46
47 private: 47 private:
48 // |histogram_snapshot_manager_| prepares histogram deltas for transmission. 48 // |histogram_snapshot_manager_| prepares histogram deltas for transmission.
49 base::HistogramSnapshotManager histogram_snapshot_manager_; 49 base::HistogramSnapshotManager histogram_snapshot_manager_;
50 50
51 DISALLOW_COPY_AND_ASSIGN(MetricsServiceBase); 51 DISALLOW_COPY_AND_ASSIGN(MetricsServiceBase);
52 }; 52 };
53 53
54 #endif // CHROME_COMMON_METRICS_METRICS_SERVICE_BASE_H_ 54 #endif // CHROME_COMMON_METRICS_METRICS_SERVICE_BASE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698