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

Side by Side Diff: net/spdy/spdy_websocket_stream.cc

Issue 10689034: SPDY - chunked upload - speech recognition doesn't work with SPDY/3 (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 5 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
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 #include "net/spdy/spdy_websocket_stream.h" 5 #include "net/spdy/spdy_websocket_stream.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "googleurl/src/gurl.h" 9 #include "googleurl/src/gurl.h"
10 #include "net/base/net_errors.h" 10 #include "net/base/net_errors.h"
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 NOTREACHED(); 94 NOTREACHED();
95 return ERR_UNEXPECTED; 95 return ERR_UNEXPECTED;
96 } 96 }
97 97
98 int SpdyWebSocketStream::OnSendBodyComplete(int status, bool* eof) { 98 int SpdyWebSocketStream::OnSendBodyComplete(int status, bool* eof) {
99 NOTREACHED(); 99 NOTREACHED();
100 *eof = true; 100 *eof = true;
101 return ERR_UNEXPECTED; 101 return ERR_UNEXPECTED;
102 } 102 }
103 103
104 int SpdyWebSocketStream::OnSendChunkedBody() {
105 NOTREACHED();
106 return ERR_UNEXPECTED;
107 }
108
109 int SpdyWebSocketStream::OnSendChunkedBodyComplete(int status, bool* eof) {
110 NOTREACHED();
111 *eof = true;
112 return ERR_UNEXPECTED;
113 }
114
104 int SpdyWebSocketStream::OnResponseReceived( 115 int SpdyWebSocketStream::OnResponseReceived(
105 const SpdyHeaderBlock& response, 116 const SpdyHeaderBlock& response,
106 base::Time response_time, int status) { 117 base::Time response_time, int status) {
107 DCHECK(delegate_); 118 DCHECK(delegate_);
108 return delegate_->OnReceivedSpdyResponseHeader(response, status); 119 return delegate_->OnReceivedSpdyResponseHeader(response, status);
109 } 120 }
110 121
111 void SpdyWebSocketStream::OnDataReceived(const char* data, int length) { 122 void SpdyWebSocketStream::OnDataReceived(const char* data, int length) {
112 DCHECK(delegate_); 123 DCHECK(delegate_);
113 delegate_->OnReceivedSpdyData(data, length); 124 delegate_->OnReceivedSpdyData(data, length);
(...skipping 12 matching lines...) Expand all
126 return; 137 return;
127 Delegate* delegate = delegate_; 138 Delegate* delegate = delegate_;
128 delegate_ = NULL; 139 delegate_ = NULL;
129 delegate->OnCloseSpdyStream(); 140 delegate->OnCloseSpdyStream();
130 } 141 }
131 142
132 void SpdyWebSocketStream::set_chunk_callback(ChunkCallback* callback) { 143 void SpdyWebSocketStream::set_chunk_callback(ChunkCallback* callback) {
133 // Do nothing. SpdyWebSocketStream doesn't send any chunked data. 144 // Do nothing. SpdyWebSocketStream doesn't send any chunked data.
134 } 145 }
135 146
147 bool SpdyWebSocketStream::IsRequestBodyChunked() {
148 return false;
149 }
150
136 void SpdyWebSocketStream::OnSpdyStreamCreated(int result) { 151 void SpdyWebSocketStream::OnSpdyStreamCreated(int result) {
137 DCHECK_NE(ERR_IO_PENDING, result); 152 DCHECK_NE(ERR_IO_PENDING, result);
138 if (result == OK) { 153 if (result == OK) {
139 DCHECK(stream_); 154 DCHECK(stream_);
140 stream_->SetDelegate(this); 155 stream_->SetDelegate(this);
141 } 156 }
142 DCHECK(delegate_); 157 DCHECK(delegate_);
143 delegate_->OnCreatedSpdyStream(result); 158 delegate_->OnCreatedSpdyStream(result);
144 } 159 }
145 160
146 } // namespace net 161 } // namespace net
OLDNEW
« net/spdy/spdy_stream_spdy2_unittest.cc ('K') | « net/spdy/spdy_websocket_stream.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698