Index: net/base/socket_performance_watcher.h |
diff --git a/net/base/socket_performance_watcher.h b/net/base/socket_performance_watcher.h |
index e0e76327ce63541e8d0dc2ba23215d34f953df41..0cc826f26092df759a4597482da36ff0d2851613 100644 |
--- a/net/base/socket_performance_watcher.h |
+++ b/net/base/socket_performance_watcher.h |
@@ -5,6 +5,9 @@ |
#ifndef NET_BASE_SOCKET_PERFORMANCE_WATCHER_H_ |
#define NET_BASE_SOCKET_PERFORMANCE_WATCHER_H_ |
+#include <stddef.h> |
+#include <stdint.h> |
+ |
#include "base/macros.h" |
#include "net/base/net_export.h" |
#include "net/base/socket_performance_watcher_factory.h" |
@@ -33,6 +36,22 @@ class NET_EXPORT_PRIVATE SocketPerformanceWatcher { |
// made, hence no timestamp. |
void OnUpdatedRTTAvailable(const base::TimeDelta& rtt) const; |
+ // Called when an updated packet count at the transport layer is available. |
+ // All the counts are since the last call to the |
+ // OnUpdatedPacketCountAvailable. This method is called immediately after the |
+ // observation is made, hence no timestamp. |
+ |
+ // An example: |
+ // Last observation after packet #1. Packets #5 and #6 are received: |
+ // lost = 3, in_order = 2, out_of_order = 0. |
+ |
+ // Last observation after packet #6. Packet #3 received: |
+ // lost = 0, in_order = 0, out_of_order = 1. |
+ void OnUpdatedPacketCountAvailable( |
+ size_t packets_lost, |
+ size_t packets_received_in_order, |
+ size_t packets_received_out_of_order) const; |
+ |
private: |
// Transport layer protocol used by the socket that |this| is watching. |
const SocketPerformanceWatcherFactory::Protocol protocol_; |