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 526 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
537 | 537 |
538 // Selects and updates the version of the protocol being used by selecting a | 538 // Selects and updates the version of the protocol being used by selecting a |
539 // version from |available_versions| which is also supported. Returns true if | 539 // version from |available_versions| which is also supported. Returns true if |
540 // such a version exists, false otherwise. | 540 // such a version exists, false otherwise. |
541 bool SelectMutualVersion(const QuicVersionVector& available_versions); | 541 bool SelectMutualVersion(const QuicVersionVector& available_versions); |
542 | 542 |
543 QuicPacketWriter* writer() { return writer_; } | 543 QuicPacketWriter* writer() { return writer_; } |
544 | 544 |
545 bool peer_port_changed() const { return peer_port_changed_; } | 545 bool peer_port_changed() const { return peer_port_changed_; } |
546 | 546 |
547 const QuicReceivedPacketManager& received_packet_manager() const { | |
548 return received_packet_manager_; | |
549 } | |
550 | |
551 QuicPacketSequenceNumber sequence_number_of_last_sent_packet() const { | 547 QuicPacketSequenceNumber sequence_number_of_last_sent_packet() const { |
552 return sequence_number_of_last_sent_packet_; | 548 return sequence_number_of_last_sent_packet_; |
553 } | 549 } |
554 | 550 |
555 private: | 551 private: |
556 friend class test::QuicConnectionPeer; | 552 friend class test::QuicConnectionPeer; |
557 | 553 |
558 // Packets which have not been written to the wire. | 554 // Packets which have not been written to the wire. |
559 // Owns the QuicPacket* packet. | 555 // Owns the QuicPacket* packet. |
560 struct QueuedPacket { | 556 struct QueuedPacket { |
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
804 // If non-empty this contains the set of versions received in a | 800 // If non-empty this contains the set of versions received in a |
805 // version negotiation packet. | 801 // version negotiation packet. |
806 QuicVersionVector server_supported_versions_; | 802 QuicVersionVector server_supported_versions_; |
807 | 803 |
808 DISALLOW_COPY_AND_ASSIGN(QuicConnection); | 804 DISALLOW_COPY_AND_ASSIGN(QuicConnection); |
809 }; | 805 }; |
810 | 806 |
811 } // namespace net | 807 } // namespace net |
812 | 808 |
813 #endif // NET_QUIC_QUIC_CONNECTION_H_ | 809 #endif // NET_QUIC_QUIC_CONNECTION_H_ |
OLD | NEW |