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

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

Issue 2077683002: Move the logic for delaying 0-RTT QUIC POST from the QuicStreamFactory (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@QuicHttpStream
Patch Set: test Created 4 years, 6 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef NET_QUIC_BIDIRECTIONAL_STREAM_QUIC_IMPL_H_ 5 #ifndef NET_QUIC_BIDIRECTIONAL_STREAM_QUIC_IMPL_H_
6 #define NET_QUIC_BIDIRECTIONAL_STREAM_QUIC_IMPL_H_ 6 #define NET_QUIC_BIDIRECTIONAL_STREAM_QUIC_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 void OnDataAvailable() override; 63 void OnDataAvailable() override;
64 void OnClose(QuicErrorCode error) override; 64 void OnClose(QuicErrorCode error) override;
65 void OnError(int error) override; 65 void OnError(int error) override;
66 bool HasSendHeadersComplete() override; 66 bool HasSendHeadersComplete() override;
67 67
68 // QuicChromiumClientSession::Observer implementation: 68 // QuicChromiumClientSession::Observer implementation:
69 void OnCryptoHandshakeConfirmed() override; 69 void OnCryptoHandshakeConfirmed() override;
70 void OnSessionClosed(int error, bool port_migration_detected) override; 70 void OnSessionClosed(int error, bool port_migration_detected) override;
71 71
72 void OnStreamReady(int rv); 72 void OnStreamReady(int rv);
73 void StartStream();
xunjieli 2016/06/17 18:05:42 We could rename it to NotifyStreamReady() to be mo
Ryan Hamilton 2016/06/17 18:20:35 Done.
73 void OnSendDataComplete(int rv); 74 void OnSendDataComplete(int rv);
74 void OnReadDataComplete(int rv); 75 void OnReadDataComplete(int rv);
75 76
76 // Notifies the delegate of an error. 77 // Notifies the delegate of an error.
77 void NotifyError(int error); 78 void NotifyError(int error);
78 // Resets the stream and ensures that |delegate_| won't be called back. 79 // Resets the stream and ensures that |delegate_| won't be called back.
79 void ResetStream(); 80 void ResetStream();
80 81
81 base::WeakPtr<QuicChromiumClientSession> session_; 82 base::WeakPtr<QuicChromiumClientSession> session_;
82 bool was_handshake_confirmed_; // True if the crypto handshake succeeded. 83 bool was_handshake_confirmed_; // True if the crypto handshake succeeded.
(...skipping 27 matching lines...) Expand all
110 bool has_sent_headers_; 111 bool has_sent_headers_;
111 // Indicates whether initial headers have been received. 112 // Indicates whether initial headers have been received.
112 bool has_received_headers_; 113 bool has_received_headers_;
113 114
114 // Whether to automatically send request headers when stream is negotiated. 115 // Whether to automatically send request headers when stream is negotiated.
115 // If false, headers will not be sent until SendRequestHeaders() is called or 116 // If false, headers will not be sent until SendRequestHeaders() is called or
116 // until next SendData/SendvData, during which QUIC will try to combine header 117 // until next SendData/SendvData, during which QUIC will try to combine header
117 // frame with data frame in the same packet if possible. 118 // frame with data frame in the same packet if possible.
118 bool send_request_headers_automatically_; 119 bool send_request_headers_automatically_;
119 120
121 // True of this stream is waiting for the QUIC handshake to be confirmed
122 // before sending headers.
123 bool waiting_for_confirmation_;
124
120 base::WeakPtrFactory<BidirectionalStreamQuicImpl> weak_factory_; 125 base::WeakPtrFactory<BidirectionalStreamQuicImpl> weak_factory_;
121 126
122 DISALLOW_COPY_AND_ASSIGN(BidirectionalStreamQuicImpl); 127 DISALLOW_COPY_AND_ASSIGN(BidirectionalStreamQuicImpl);
123 }; 128 };
124 129
125 } // namespace net 130 } // namespace net
126 131
127 #endif // NET_QUIC_BIDIRECTIONAL_STREAM_QUIC_IMPL_H_ 132 #endif // NET_QUIC_BIDIRECTIONAL_STREAM_QUIC_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | net/quic/bidirectional_stream_quic_impl.cc » ('j') | net/quic/bidirectional_stream_quic_impl_unittest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698