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

Side by Side Diff: net/quic/quic_connection.h

Issue 1714713002: Landing Recent QUIC changes until 2/12/2016 21:32 UTC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 unified diff | Download patch
« no previous file with comments | « net/quic/quic_chromium_client_session.cc ('k') | net/quic/quic_connection.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // The entity that handles framing writes for a Quic client or server. 5 // The entity that handles framing writes for a Quic client or server.
6 // Each QuicSession will have a connection associated with it. 6 // Each QuicSession will have a connection associated with it.
7 // 7 //
8 // On the server side, the Dispatcher handles the raw reads, and hands off 8 // On the server side, the Dispatcher handles the raw reads, and hands off
9 // packets via ProcessUdpPacket for framing and processing. 9 // packets via ProcessUdpPacket for framing and processing.
10 // 10 //
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 154
155 // Called to ask if any streams are open in this visitor, excluding the 155 // Called to ask if any streams are open in this visitor, excluding the
156 // reserved crypto and headers stream. 156 // reserved crypto and headers stream.
157 virtual bool HasOpenDynamicStreams() const = 0; 157 virtual bool HasOpenDynamicStreams() const = 0;
158 }; 158 };
159 159
160 // Interface which gets callbacks from the QuicConnection at interesting 160 // Interface which gets callbacks from the QuicConnection at interesting
161 // points. Implementations must not mutate the state of the connection 161 // points. Implementations must not mutate the state of the connection
162 // as a result of these callbacks. 162 // as a result of these callbacks.
163 class NET_EXPORT_PRIVATE QuicConnectionDebugVisitor 163 class NET_EXPORT_PRIVATE QuicConnectionDebugVisitor
164 : public QuicPacketCreator::DebugDelegate, 164 : public QuicSentPacketManager::DebugDelegate {
165 public QuicSentPacketManager::DebugDelegate {
166 public: 165 public:
167 ~QuicConnectionDebugVisitor() override {} 166 ~QuicConnectionDebugVisitor() override {}
168 167
169 // Called when a packet has been sent. 168 // Called when a packet has been sent.
170 virtual void OnPacketSent(const SerializedPacket& serialized_packet, 169 virtual void OnPacketSent(const SerializedPacket& serialized_packet,
171 QuicPacketNumber original_packet_number, 170 QuicPacketNumber original_packet_number,
172 TransmissionType transmission_type, 171 TransmissionType transmission_type,
173 size_t encrypted_length, 172 size_t encrypted_length,
174 QuicTime sent_time) {} 173 QuicTime sent_time) {}
175 174
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
483 // case this is when the SHLO has been ACKed. Clients call this on receipt of 482 // case this is when the SHLO has been ACKed. Clients call this on receipt of
484 // the SHLO. 483 // the SHLO.
485 void OnHandshakeComplete(); 484 void OnHandshakeComplete();
486 485
487 // Accessors 486 // Accessors
488 void set_visitor(QuicConnectionVisitorInterface* visitor) { 487 void set_visitor(QuicConnectionVisitorInterface* visitor) {
489 visitor_ = visitor; 488 visitor_ = visitor;
490 } 489 }
491 void set_debug_visitor(QuicConnectionDebugVisitor* debug_visitor) { 490 void set_debug_visitor(QuicConnectionDebugVisitor* debug_visitor) {
492 debug_visitor_ = debug_visitor; 491 debug_visitor_ = debug_visitor;
493 packet_generator_.set_debug_delegate(debug_visitor);
494 sent_packet_manager_.set_debug_delegate(debug_visitor); 492 sent_packet_manager_.set_debug_delegate(debug_visitor);
495 } 493 }
494 // Used in Chromium, but not internally.
495 void set_creator_debug_delegate(QuicPacketCreator::DebugDelegate* visitor) {
496 packet_generator_.set_debug_delegate(visitor);
497 }
496 const IPEndPoint& self_address() const { return self_address_; } 498 const IPEndPoint& self_address() const { return self_address_; }
497 const IPEndPoint& peer_address() const { return peer_address_; } 499 const IPEndPoint& peer_address() const { return peer_address_; }
498 QuicConnectionId connection_id() const { return connection_id_; } 500 QuicConnectionId connection_id() const { return connection_id_; }
499 const QuicClock* clock() const { return clock_; } 501 const QuicClock* clock() const { return clock_; }
500 QuicRandom* random_generator() const { return random_generator_; } 502 QuicRandom* random_generator() const { return random_generator_; }
501 QuicByteCount max_packet_length() const; 503 QuicByteCount max_packet_length() const;
502 void SetMaxPacketLength(QuicByteCount length); 504 void SetMaxPacketLength(QuicByteCount length);
503 505
504 size_t mtu_probe_count() const { return mtu_probe_count_; } 506 size_t mtu_probe_count() const { return mtu_probe_count_; }
505 507
(...skipping 546 matching lines...) Expand 10 before | Expand all | Expand 10 after
1052 1054
1053 // If true, multipath is enabled for this connection. 1055 // If true, multipath is enabled for this connection.
1054 bool multipath_enabled_; 1056 bool multipath_enabled_;
1055 1057
1056 DISALLOW_COPY_AND_ASSIGN(QuicConnection); 1058 DISALLOW_COPY_AND_ASSIGN(QuicConnection);
1057 }; 1059 };
1058 1060
1059 } // namespace net 1061 } // namespace net
1060 1062
1061 #endif // NET_QUIC_QUIC_CONNECTION_H_ 1063 #endif // NET_QUIC_QUIC_CONNECTION_H_
OLDNEW
« no previous file with comments | « net/quic/quic_chromium_client_session.cc ('k') | net/quic/quic_connection.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698