| OLD | NEW |
| 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 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 359 | 359 |
| 360 // QuicPacketGenerator::DelegateInterface | 360 // QuicPacketGenerator::DelegateInterface |
| 361 virtual bool ShouldGeneratePacket(TransmissionType transmission_type, | 361 virtual bool ShouldGeneratePacket(TransmissionType transmission_type, |
| 362 HasRetransmittableData retransmittable, | 362 HasRetransmittableData retransmittable, |
| 363 IsHandshake handshake) OVERRIDE; | 363 IsHandshake handshake) OVERRIDE; |
| 364 virtual QuicAckFrame* CreateAckFrame() OVERRIDE; | 364 virtual QuicAckFrame* CreateAckFrame() OVERRIDE; |
| 365 virtual QuicCongestionFeedbackFrame* CreateFeedbackFrame() OVERRIDE; | 365 virtual QuicCongestionFeedbackFrame* CreateFeedbackFrame() OVERRIDE; |
| 366 virtual QuicStopWaitingFrame* CreateStopWaitingFrame() OVERRIDE; | 366 virtual QuicStopWaitingFrame* CreateStopWaitingFrame() OVERRIDE; |
| 367 virtual bool OnSerializedPacket(const SerializedPacket& packet) OVERRIDE; | 367 virtual bool OnSerializedPacket(const SerializedPacket& packet) OVERRIDE; |
| 368 | 368 |
| 369 // Called by the crypto stream when the handshake completes. In the server's |
| 370 // case this is when the SHLO has been ACKed. Clients call this on receipt of |
| 371 // the SHLO. |
| 372 void OnHandshakeComplete(); |
| 373 |
| 369 // Accessors | 374 // Accessors |
| 370 void set_visitor(QuicConnectionVisitorInterface* visitor) { | 375 void set_visitor(QuicConnectionVisitorInterface* visitor) { |
| 371 visitor_ = visitor; | 376 visitor_ = visitor; |
| 372 } | 377 } |
| 373 void set_debug_visitor(QuicConnectionDebugVisitor* debug_visitor) { | 378 void set_debug_visitor(QuicConnectionDebugVisitor* debug_visitor) { |
| 374 debug_visitor_.reset(debug_visitor); | 379 debug_visitor_.reset(debug_visitor); |
| 375 packet_generator_.set_debug_delegate(debug_visitor); | 380 packet_generator_.set_debug_delegate(debug_visitor); |
| 376 sent_packet_manager_.set_debug_delegate(debug_visitor); | 381 sent_packet_manager_.set_debug_delegate(debug_visitor); |
| 377 } | 382 } |
| 378 const IPEndPoint& self_address() const { return self_address_; } | 383 const IPEndPoint& self_address() const { return self_address_; } |
| (...skipping 411 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 790 // If non-empty this contains the set of versions received in a | 795 // If non-empty this contains the set of versions received in a |
| 791 // version negotiation packet. | 796 // version negotiation packet. |
| 792 QuicVersionVector server_supported_versions_; | 797 QuicVersionVector server_supported_versions_; |
| 793 | 798 |
| 794 DISALLOW_COPY_AND_ASSIGN(QuicConnection); | 799 DISALLOW_COPY_AND_ASSIGN(QuicConnection); |
| 795 }; | 800 }; |
| 796 | 801 |
| 797 } // namespace net | 802 } // namespace net |
| 798 | 803 |
| 799 #endif // NET_QUIC_QUIC_CONNECTION_H_ | 804 #endif // NET_QUIC_QUIC_CONNECTION_H_ |
| OLD | NEW |