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

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

Issue 2927453002: Make NQE a derived class of NetworkQualityProvider (Closed)
Patch Set: some more IWYU fixes Created 3 years, 6 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 | « net/nqe/network_quality_provider.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2017 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 NET_NQE_NETWORK_QUALITY_RTT_THROUGHPUT_ESTIMATES_OBSERVER_H_
6 #define NET_NQE_NETWORK_QUALITY_RTT_THROUGHPUT_ESTIMATES_OBSERVER_H_
7
8 #include <stdint.h>
9
10 #include "base/compiler_specific.h"
11 #include "base/macros.h"
12 #include "base/time/time.h"
13 #include "net/base/net_export.h"
14
15 namespace net {
16
17 // Observes changes in the network quality.
18 class NET_EXPORT RTTAndThroughputEstimatesObserver {
19 public:
20 // Notifies the observer when estimated HTTP RTT, estimated transport RTT or
21 // estimated downstream throughput is computed. NetworkQualityEstimator
22 // computes the RTT and throughput estimates at regular intervals.
23 // Additionally, when there is a change in the connection type of the
24 // device, then the estimates are immediately computed.
25 //
26 // |http_rtt|, |transport_rtt| and |downstream_throughput_kbps| are the
27 // computed estimates of the HTTP RTT, transport RTT and downstream
28 // throughput (in kilobits per second), respectively. If an estimate of the
29 // HTTP or transport RTT is unavailable, it will be set to
30 // nqe::internal::InvalidRTT(). If the throughput estimate is unavailable,
31 // it will be set to nqe::internal::kInvalidThroughput.
32 virtual void OnRTTOrThroughputEstimatesComputed(
33 base::TimeDelta http_rtt,
34 base::TimeDelta transport_rtt,
35 int32_t downstream_throughput_kbps) = 0;
36
37 virtual ~RTTAndThroughputEstimatesObserver() {}
38
39 protected:
40 RTTAndThroughputEstimatesObserver() {}
41
42 private:
43 DISALLOW_COPY_AND_ASSIGN(RTTAndThroughputEstimatesObserver);
44 };
45
46 } // namespace net
47
48 #endif // NET_NQE_NETWORK_QUALITY_RTT_THROUGHPUT_ESTIMATES_OBSERVER_H_
OLDNEW
« no previous file with comments | « net/nqe/network_quality_provider.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698