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

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

Issue 7189055: Deciding best connection to schedule requests on based on cwnd and idle time (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: syncing to head Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_proxy_client_socket.h" 5 #include "net/spdy/spdy_proxy_client_socket.h"
6 6
7 #include <algorithm> // min 7 #include <algorithm> // min
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/string_util.h" 10 #include "base/string_util.h"
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 } 131 }
132 132
133 bool SpdyProxyClientSocket::WasEverUsed() const { 133 bool SpdyProxyClientSocket::WasEverUsed() const {
134 return was_ever_used_ || (spdy_stream_ && spdy_stream_->WasEverUsed()); 134 return was_ever_used_ || (spdy_stream_ && spdy_stream_->WasEverUsed());
135 } 135 }
136 136
137 bool SpdyProxyClientSocket::UsingTCPFastOpen() const { 137 bool SpdyProxyClientSocket::UsingTCPFastOpen() const {
138 return false; 138 return false;
139 } 139 }
140 140
141 int64 SpdyProxyClientSocket::NumBytesRead() const {
142 return -1;
143 }
144
145 int SpdyProxyClientSocket::GetConnectTimeMicros() const {
146 return -1;
147 }
148
141 int SpdyProxyClientSocket::Read(IOBuffer* buf, int buf_len, 149 int SpdyProxyClientSocket::Read(IOBuffer* buf, int buf_len,
142 CompletionCallback* callback) { 150 CompletionCallback* callback) {
143 DCHECK(!read_callback_); 151 DCHECK(!read_callback_);
144 DCHECK(!user_buffer_); 152 DCHECK(!user_buffer_);
145 153
146 if (next_state_ == STATE_DISCONNECTED) 154 if (next_state_ == STATE_DISCONNECTED)
147 return ERR_SOCKET_NOT_CONNECTED; 155 return ERR_SOCKET_NOT_CONNECTED;
148 156
149 if (!spdy_stream_ && read_buffer_.empty()) { 157 if (!spdy_stream_ && read_buffer_.empty()) {
150 if (eof_has_been_read_) 158 if (eof_has_been_read_)
(...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after
502 OnDataReceived(NULL, 0); 510 OnDataReceived(NULL, 0);
503 } 511 }
504 if (write_callback) 512 if (write_callback)
505 write_callback->Run(ERR_CONNECTION_CLOSED); 513 write_callback->Run(ERR_CONNECTION_CLOSED);
506 } 514 }
507 515
508 void SpdyProxyClientSocket::set_chunk_callback(ChunkCallback* /*callback*/) { 516 void SpdyProxyClientSocket::set_chunk_callback(ChunkCallback* /*callback*/) {
509 } 517 }
510 518
511 } // namespace net 519 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698