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

Side by Side Diff: net/nqe/cached_network_quality.h

Issue 2369673004: Wire NQE Prefs to Profile (Closed)
Patch Set: More fixups Created 4 years, 2 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
« no previous file with comments | « chrome/common/pref_names.cc ('k') | net/nqe/cached_network_quality.cc » ('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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_NQE_CACHED_NETWORK_QUALITY_H_ 5 #ifndef NET_NQE_CACHED_NETWORK_QUALITY_H_
6 #define NET_NQE_CACHED_NETWORK_QUALITY_H_ 6 #define NET_NQE_CACHED_NETWORK_QUALITY_H_
7 7
8 #include "base/time/time.h" 8 #include "base/time/time.h"
9 #include "net/base/net_export.h" 9 #include "net/base/net_export.h"
10 #include "net/nqe/effective_connection_type.h" 10 #include "net/nqe/effective_connection_type.h"
11 #include "net/nqe/network_quality.h" 11 #include "net/nqe/network_quality.h"
12 12
13 namespace net { 13 namespace net {
14 14
15 namespace nqe { 15 namespace nqe {
16 16
17 namespace internal { 17 namespace internal {
18 18
19 // CachedNetworkQuality stores the quality of a previously seen network. 19 // CachedNetworkQuality stores the quality of a previously seen network.
20 class NET_EXPORT_PRIVATE CachedNetworkQuality { 20 class NET_EXPORT_PRIVATE CachedNetworkQuality {
21 public: 21 public:
22 CachedNetworkQuality(); 22 CachedNetworkQuality();
23 explicit CachedNetworkQuality(
24 EffectiveConnectionType effective_connection_type);
23 25
24 // |last_update_time| is the time when the |network_quality| was computed. 26 // |last_update_time| is the time when the |network_quality| was computed.
25 CachedNetworkQuality(base::TimeTicks last_update_time, 27 CachedNetworkQuality(base::TimeTicks last_update_time,
26 const NetworkQuality& network_quality, 28 const NetworkQuality& network_quality,
27 EffectiveConnectionType effective_connection_type); 29 EffectiveConnectionType effective_connection_type);
28 CachedNetworkQuality(const CachedNetworkQuality& other); 30 CachedNetworkQuality(const CachedNetworkQuality& other);
29 ~CachedNetworkQuality(); 31 ~CachedNetworkQuality();
30 32
31 // Returns the network quality associated with this cached entry. 33 // Returns the network quality associated with this cached entry.
32 const NetworkQuality& network_quality() const { return network_quality_; } 34 const NetworkQuality& network_quality() const { return network_quality_; }
(...skipping 23 matching lines...) Expand all
56 EffectiveConnectionType effective_connection_type_; 58 EffectiveConnectionType effective_connection_type_;
57 }; 59 };
58 60
59 } // namespace internal 61 } // namespace internal
60 62
61 } // namespace nqe 63 } // namespace nqe
62 64
63 } // namespace net 65 } // namespace net
64 66
65 #endif // NET_NQE_CACHED_NETWORK_QUALITY_H_ 67 #endif // NET_NQE_CACHED_NETWORK_QUALITY_H_
OLDNEW
« no previous file with comments | « chrome/common/pref_names.cc ('k') | net/nqe/cached_network_quality.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698