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

Unified Diff: components/cronet/android/java/src/org/chromium/net/NetworkQualityRttListener.java

Issue 1273173002: Added Network Quality Estimator Real-time interface to Cronet (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nit Created 5 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 side-by-side diff with in-line comments
Download patch
Index: components/cronet/android/java/src/org/chromium/net/NetworkQualityRttListener.java
diff --git a/components/cronet/android/java/src/org/chromium/net/NetworkQualityRttListener.java b/components/cronet/android/java/src/org/chromium/net/NetworkQualityRttListener.java
new file mode 100644
index 0000000000000000000000000000000000000000..381b477a0e383eb59204022959e8259a2dcd4c61
--- /dev/null
+++ b/components/cronet/android/java/src/org/chromium/net/NetworkQualityRttListener.java
@@ -0,0 +1,21 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package org.chromium.net;
+
+/**
+ * Interface to watch for observations of various round trip times (RTTs) at
+ * various layers of the network stack. These include RTT estimates by QUIC
+ * and TCP, as well as the time between when a URL request is sent and when
+ * the first byte of the response is received.
+ */
+public interface NetworkQualityRttListener {
+ /**
+ * Reports a new round trip time observation.
+ * @param rttMs the round trip time in milliseconds.
+ * @param whenMs milliseconds since the Epoch (January 1st 1970, 00:00:00.000).
+ * @param source the observation source from {@link NetworkQualityObservationSource}.
+ */
+ public void onRttObservation(int rttMs, long whenMs, int source);
+}

Powered by Google App Engine
This is Rietveld 408576698