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

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

Issue 188333003: Land Recent QUIC Changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix compilation error - added NET_EXPORT_PRIVATE to QuicFixedUint32 Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « net/quic/quic_config_test.cc ('k') | net/quic/quic_connection_test.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 509 matching lines...) Expand 10 before | Expand all | Expand 10 after
520 520
521 // Make sure an ack we got from our peer is sane. 521 // Make sure an ack we got from our peer is sane.
522 bool ValidateAckFrame(const QuicAckFrame& incoming_ack); 522 bool ValidateAckFrame(const QuicAckFrame& incoming_ack);
523 523
524 // Sends a version negotiation packet to the peer. 524 // Sends a version negotiation packet to the peer.
525 void SendVersionNegotiationPacket(); 525 void SendVersionNegotiationPacket();
526 526
527 // Clears any accumulated frames from the last received packet. 527 // Clears any accumulated frames from the last received packet.
528 void ClearLastFrames(); 528 void ClearLastFrames();
529 529
530 // Calculates the smallest sequence number length that can also represent four
531 // times the maximum of the congestion window and the difference between the
532 // least_packet_awaited_by_peer_ and |sequence_number|.
533 QuicSequenceNumberLength CalculateSequenceNumberLength(
534 QuicPacketSequenceNumber sequence_number);
535
536 // Drop packet corresponding to |sequence_number| by deleting entries from
537 // |unacked_packets_| and |retransmission_map_|, if present. We need to drop
538 // all packets with encryption level NONE after the default level has been set
539 // to FORWARD_SECURE.
540 void DropPacket(QuicPacketSequenceNumber sequence_number);
541
542 // Writes as many queued packets as possible. The connection must not be 530 // Writes as many queued packets as possible. The connection must not be
543 // blocked when this is called. 531 // blocked when this is called.
544 void WriteQueuedPackets(); 532 void WriteQueuedPackets();
545 533
546 // Writes as many pending retransmissions as possible. 534 // Writes as many pending retransmissions as possible.
547 void WritePendingRetransmissions(); 535 void WritePendingRetransmissions();
548 536
549 // Returns true if the packet should be discarded and not sent. 537 // Returns true if the packet should be discarded and not sent.
550 bool ShouldDiscardPacket(EncryptionLevel level, 538 bool ShouldDiscardPacket(EncryptionLevel level,
551 QuicPacketSequenceNumber sequence_number, 539 QuicPacketSequenceNumber sequence_number,
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
724 // If non-empty this contains the set of versions received in a 712 // If non-empty this contains the set of versions received in a
725 // version negotiation packet. 713 // version negotiation packet.
726 QuicVersionVector server_supported_versions_; 714 QuicVersionVector server_supported_versions_;
727 715
728 DISALLOW_COPY_AND_ASSIGN(QuicConnection); 716 DISALLOW_COPY_AND_ASSIGN(QuicConnection);
729 }; 717 };
730 718
731 } // namespace net 719 } // namespace net
732 720
733 #endif // NET_QUIC_QUIC_CONNECTION_H_ 721 #endif // NET_QUIC_QUIC_CONNECTION_H_
OLDNEW
« no previous file with comments | « net/quic/quic_config_test.cc ('k') | net/quic/quic_connection_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698