| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_QUIC_QUIC_SENT_PACKET_MANAGER_H_ | 5 #ifndef NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ |
| 6 #define NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ | 6 #define NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 QuicTime detection_time) {} | 88 QuicTime detection_time) {} |
| 89 }; | 89 }; |
| 90 | 90 |
| 91 // Interface which gets callbacks from the QuicSentPacketManager when | 91 // Interface which gets callbacks from the QuicSentPacketManager when |
| 92 // network-related state changes. Implementations must not mutate the | 92 // network-related state changes. Implementations must not mutate the |
| 93 // state of the packet manager as a result of these callbacks. | 93 // state of the packet manager as a result of these callbacks. |
| 94 class NET_EXPORT_PRIVATE NetworkChangeVisitor { | 94 class NET_EXPORT_PRIVATE NetworkChangeVisitor { |
| 95 public: | 95 public: |
| 96 virtual ~NetworkChangeVisitor() {} | 96 virtual ~NetworkChangeVisitor() {} |
| 97 | 97 |
| 98 // Called when congestion window may have changed. | 98 // Called when congestion window or RTT may have changed. |
| 99 virtual void OnCongestionWindowChange() = 0; | 99 virtual void OnCongestionChange() = 0; |
| 100 | |
| 101 // Called when RTT may have changed, including when an RTT is read from | |
| 102 // the config. | |
| 103 virtual void OnRttChange() = 0; | |
| 104 | 100 |
| 105 // Called with the path may be degrading. Note that the path may only be | 101 // Called with the path may be degrading. Note that the path may only be |
| 106 // temporarily degrading. | 102 // temporarily degrading. |
| 107 // TODO(jri): With multipath, this method should probably have a path_id | 103 // TODO(jri): With multipath, this method should probably have a path_id |
| 108 // parameter, and should maybe result in the path being marked as inactive. | 104 // parameter, and should maybe result in the path being marked as inactive. |
| 109 virtual void OnPathDegrading() = 0; | 105 virtual void OnPathDegrading() = 0; |
| 110 }; | 106 }; |
| 111 | 107 |
| 112 QuicSentPacketManager(Perspective perspective, | 108 QuicSentPacketManager(Perspective perspective, |
| 113 QuicPathId path_id, | 109 QuicPathId path_id, |
| (...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 454 // Records bandwidth from server to client in normal operation, over periods | 450 // Records bandwidth from server to client in normal operation, over periods |
| 455 // of time with no loss events. | 451 // of time with no loss events. |
| 456 QuicSustainedBandwidthRecorder sustained_bandwidth_recorder_; | 452 QuicSustainedBandwidthRecorder sustained_bandwidth_recorder_; |
| 457 | 453 |
| 458 DISALLOW_COPY_AND_ASSIGN(QuicSentPacketManager); | 454 DISALLOW_COPY_AND_ASSIGN(QuicSentPacketManager); |
| 459 }; | 455 }; |
| 460 | 456 |
| 461 } // namespace net | 457 } // namespace net |
| 462 | 458 |
| 463 #endif // NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ | 459 #endif // NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ |
| OLD | NEW |