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

Side by Side Diff: base/metrics/histogram_base.cc

Issue 10830156: Skeleton code of 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
« no previous file with comments | « base/metrics/histogram_base.h ('k') | base/metrics/sparse_histogram.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include "base/metrics/histogram_base.h" 5 #include "base/metrics/histogram_base.h"
6 6
7 #include <climits>
8
7 namespace base { 9 namespace base {
8 10
9 const HistogramBase::Sample HistogramBase::kSampleType_MAX = INT_MAX; 11 const HistogramBase::Sample HistogramBase::kSampleType_MAX = INT_MAX;
10 12
11 HistogramBase::HistogramBase(const std::string& name) 13 HistogramBase::HistogramBase(const std::string& name)
12 : histogram_name_(name) {} 14 : histogram_name_(name),
15 flags_(kNoFlags) {}
13 16
14 HistogramBase::~HistogramBase() {} 17 HistogramBase::~HistogramBase() {}
15 18
19 void HistogramBase::SetFlags(int32 flags) {
20 flags_ |= flags;
21 }
22
23 void HistogramBase::ClearFlags(int32 flags) {
24 flags_ &= ~flags;
25 }
26
16 } // namespace base 27 } // namespace base
OLDNEW
« no previous file with comments | « base/metrics/histogram_base.h ('k') | base/metrics/sparse_histogram.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698