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

Unified Diff: net/nqe/network_quality_estimator.cc

Issue 2911473002: Expose transport RTT estimate from Network Quality Estimator (NQE) (Closed)
Patch Set: ryansturm comment Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/nqe/network_quality_estimator.h ('k') | net/nqe/network_quality_estimator_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/nqe/network_quality_estimator.cc
diff --git a/net/nqe/network_quality_estimator.cc b/net/nqe/network_quality_estimator.cc
index 6b9be0358afaf6c2a77bb6453f0048b6360bf7b3..8759b0fb4324cef241909f79fe3adf3fb2c12ec5 100644
--- a/net/nqe/network_quality_estimator.cc
+++ b/net/nqe/network_quality_estimator.cc
@@ -1767,6 +1767,15 @@ void NetworkQualityEstimator::OnPrefsRead(
}
}
+base::Optional<base::TimeDelta> NetworkQualityEstimator::GetTransportRTT()
+ const {
+ DCHECK(thread_checker_.CalledOnValidThread());
+
+ if (network_quality_.transport_rtt() == nqe::internal::InvalidRTT())
+ return base::Optional<base::TimeDelta>();
+ return network_quality_.transport_rtt();
+}
+
void NetworkQualityEstimator::MaybeUpdateNetworkQualityFromCache(
const nqe::internal::NetworkID& network_id,
const nqe::internal::CachedNetworkQuality& cached_network_quality) {
« no previous file with comments | « net/nqe/network_quality_estimator.h ('k') | net/nqe/network_quality_estimator_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698