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

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

Issue 12806002: Land Recent QUIC Changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: minor comment fix Created 7 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_packet_creator_test.cc ('k') | net/quic/quic_packet_generator.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 // Responsible for generating packets on behalf of a QuicConnection. 5 // Responsible for generating packets on behalf of a QuicConnection.
6 // Packets are serialized just-in-time. Control frames are queued. 6 // Packets are serialized just-in-time. Control frames are queued.
7 // Ack and Feedback frames will be requested from the Connection 7 // Ack and Feedback frames will be requested from the Connection
8 // just-in-time. When a packet needs to be sent, the Generator 8 // just-in-time. When a packet needs to be sent, the Generator
9 // will serialized a packet and pass it to QuicConnection::SendOrQueuePacket() 9 // will serialized a packet and pass it to QuicConnection::SendOrQueuePacket()
10 // 10 //
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 #include "net/quic/quic_packet_creator.h" 56 #include "net/quic/quic_packet_creator.h"
57 57
58 namespace net { 58 namespace net {
59 59
60 class NET_EXPORT_PRIVATE QuicPacketGenerator { 60 class NET_EXPORT_PRIVATE QuicPacketGenerator {
61 public: 61 public:
62 class NET_EXPORT_PRIVATE DelegateInterface { 62 class NET_EXPORT_PRIVATE DelegateInterface {
63 public: 63 public:
64 virtual ~DelegateInterface() {} 64 virtual ~DelegateInterface() {}
65 virtual bool CanWrite(bool is_retransmission) = 0; 65 virtual bool CanWrite(bool is_retransmission,
66 bool has_retransmittable_data) = 0;
66 virtual QuicAckFrame* CreateAckFrame() = 0; 67 virtual QuicAckFrame* CreateAckFrame() = 0;
67 virtual QuicCongestionFeedbackFrame* CreateFeedbackFrame() = 0; 68 virtual QuicCongestionFeedbackFrame* CreateFeedbackFrame() = 0;
68 // Takes ownership of |packet.packet| and |packet.retransmittable_frames|. 69 // Takes ownership of |packet.packet| and |packet.retransmittable_frames|.
69 virtual bool OnSerializedPacket(const SerializedPacket& packet) = 0; 70 virtual bool OnSerializedPacket(const SerializedPacket& packet) = 0;
70 }; 71 };
71 72
72 QuicPacketGenerator(DelegateInterface* delegate, 73 QuicPacketGenerator(DelegateInterface* delegate,
73 QuicPacketCreator* creator); 74 QuicPacketCreator* creator);
74 75
75 virtual ~QuicPacketGenerator(); 76 virtual ~QuicPacketGenerator();
(...skipping 28 matching lines...) Expand all
104 scoped_ptr<QuicAckFrame> pending_ack_frame_; 105 scoped_ptr<QuicAckFrame> pending_ack_frame_;
105 scoped_ptr<QuicCongestionFeedbackFrame> pending_feedback_frame_; 106 scoped_ptr<QuicCongestionFeedbackFrame> pending_feedback_frame_;
106 bool should_send_feedback_; 107 bool should_send_feedback_;
107 108
108 DISALLOW_COPY_AND_ASSIGN(QuicPacketGenerator); 109 DISALLOW_COPY_AND_ASSIGN(QuicPacketGenerator);
109 }; 110 };
110 111
111 } // namespace net 112 } // namespace net
112 113
113 #endif // NET_QUIC_QUIC_PACKET_GENERATOR_H_ 114 #endif // NET_QUIC_QUIC_PACKET_GENERATOR_H_
OLDNEW
« no previous file with comments | « net/quic/quic_packet_creator_test.cc ('k') | net/quic/quic_packet_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698