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 #include "net/quic/quic_connection_stats.h" | 5 #include "net/quic/quic_connection_stats.h" |
6 | 6 |
7 using std::ostream; | 7 using std::ostream; |
8 | 8 |
9 namespace net { | 9 namespace net { |
10 | 10 |
(...skipping 24 matching lines...) Expand all Loading... |
35 estimated_bandwidth(QuicBandwidth::Zero()), | 35 estimated_bandwidth(QuicBandwidth::Zero()), |
36 packets_reordered(0), | 36 packets_reordered(0), |
37 max_sequence_reordering(0), | 37 max_sequence_reordering(0), |
38 max_time_reordering_us(0), | 38 max_time_reordering_us(0), |
39 tcp_loss_events(0), | 39 tcp_loss_events(0), |
40 connection_creation_time(QuicTime::Zero()) { | 40 connection_creation_time(QuicTime::Zero()) { |
41 } | 41 } |
42 | 42 |
43 QuicConnectionStats::~QuicConnectionStats() {} | 43 QuicConnectionStats::~QuicConnectionStats() {} |
44 | 44 |
45 ostream& operator<<(ostream& os, const QuicConnectionStats& s) { | |
46 os << "{ bytes sent: " << s.bytes_sent | |
47 << ", packets sent:" << s.packets_sent | |
48 << ", stream bytes sent: " << s.stream_bytes_sent | |
49 << ", packets discarded: " << s.packets_discarded | |
50 << ", bytes received: " << s.bytes_received | |
51 << ", packets received: " << s.packets_received | |
52 << ", packets processed: " << s.packets_processed | |
53 << ", stream bytes received: " << s.stream_bytes_received | |
54 << ", bytes retransmitted: " << s.bytes_retransmitted | |
55 << ", packets retransmitted: " << s.packets_retransmitted | |
56 << ", bytes spuriously retransmitted: " << s.bytes_spuriously_retransmitted | |
57 << ", packets spuriously retransmitted: " | |
58 << s.packets_spuriously_retransmitted | |
59 << ", packets lost: " << s.packets_lost | |
60 << ", slowstart packets lost: " << s.slowstart_packets_lost | |
61 << ", packets revived: " << s.packets_revived | |
62 << ", packets dropped:" << s.packets_dropped | |
63 << ", crypto retransmit count: " << s.crypto_retransmit_count | |
64 << ", tlp count: " << s.tlp_count | |
65 << ", rto count: " << s.rto_count | |
66 << ", min_rtt(us): " << s.min_rtt_us | |
67 << ", srtt(us): " << s.srtt_us | |
68 << ", max packet size: " << s.max_packet_size | |
69 << ", estimated bandwidth: " << s.estimated_bandwidth.ToBytesPerSecond() | |
70 << ", tcp_loss_events: " << s.tcp_loss_events | |
71 << ", packets reordered: " << s.packets_reordered | |
72 << ", max sequence reordering: " << s.max_sequence_reordering | |
73 << ", max time reordering(us): " << s.max_time_reordering_us | |
74 << "}\n"; | |
75 return os; | |
76 } | |
77 | |
78 } // namespace net | 45 } // namespace net |
OLD | NEW |