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

Side by Side Diff: net/base/bandwidth_metrics.h

Issue 18054009: Use a direct include of time headers in net/, part 1. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 5 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 | « net/base/backoff_entry.h ('k') | net/base/capturing_net_log.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 NET_BASE_BANDWIDTH_METRICS_H_ 5 #ifndef NET_BASE_BANDWIDTH_METRICS_H_
6 #define NET_BASE_BANDWIDTH_METRICS_H_ 6 #define NET_BASE_BANDWIDTH_METRICS_H_
7 7
8 #include <list> 8 #include <list>
9 9
10 #include "base/logging.h"
10 #include "base/metrics/histogram.h" 11 #include "base/metrics/histogram.h"
11 #include "base/logging.h" 12 #include "base/time/time.h"
12 #include "base/time.h"
13 13
14 namespace net { 14 namespace net {
15 15
16 // Tracks statistics about the bandwidth metrics over time. In order to 16 // Tracks statistics about the bandwidth metrics over time. In order to
17 // measure, this class needs to know when individual streams are in progress, 17 // measure, this class needs to know when individual streams are in progress,
18 // so that it can know when to discount idle time. The BandwidthMetrics 18 // so that it can know when to discount idle time. The BandwidthMetrics
19 // is unidirectional - it should only be used to record upload or download 19 // is unidirectional - it should only be used to record upload or download
20 // bandwidth, but not both. 20 // bandwidth, but not both.
21 // 21 //
22 // Note, the easiest thing to do is to just measure each stream and average 22 // Note, the easiest thing to do is to just measure each stream and average
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 void StopStream(); 127 void StopStream();
128 void RecordBytes(int bytes); 128 void RecordBytes(int bytes);
129 129
130 private: 130 private:
131 bool started_; 131 bool started_;
132 }; 132 };
133 133
134 } // namespace net 134 } // namespace net
135 135
136 #endif // NET_BASE_BANDWIDTH_METRICS_H_ 136 #endif // NET_BASE_BANDWIDTH_METRICS_H_
OLDNEW
« no previous file with comments | « net/base/backoff_entry.h ('k') | net/base/capturing_net_log.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698