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

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

Issue 6990036: 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 head and addressing comments 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 // Not implemented yet.
willchan no longer on Chromium 2011/06/13 15:06:07 Are you going to implement this?
Gagan 2011/06/13 16:45:58 dont think we need to. am not calling NOTREACHED
143 return -1;
144 }
145
146 int SpdyProxyClientSocket::GetConnectTimeMicros() const {
147 // Not implemented yet.
148 return -1;
149 }
150
141 int SpdyProxyClientSocket::Read(IOBuffer* buf, int buf_len, 151 int SpdyProxyClientSocket::Read(IOBuffer* buf, int buf_len,
142 CompletionCallback* callback) { 152 CompletionCallback* callback) {
143 DCHECK(!read_callback_); 153 DCHECK(!read_callback_);
144 DCHECK(!user_buffer_); 154 DCHECK(!user_buffer_);
145 155
146 if (next_state_ == STATE_DISCONNECTED) 156 if (next_state_ == STATE_DISCONNECTED)
147 return ERR_SOCKET_NOT_CONNECTED; 157 return ERR_SOCKET_NOT_CONNECTED;
148 158
149 if (!spdy_stream_ && read_buffer_.empty()) { 159 if (!spdy_stream_ && read_buffer_.empty()) {
150 if (eof_has_been_read_) 160 if (eof_has_been_read_)
(...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after
502 OnDataReceived(NULL, 0); 512 OnDataReceived(NULL, 0);
503 } 513 }
504 if (write_callback) 514 if (write_callback)
505 write_callback->Run(ERR_CONNECTION_CLOSED); 515 write_callback->Run(ERR_CONNECTION_CLOSED);
506 } 516 }
507 517
508 void SpdyProxyClientSocket::set_chunk_callback(ChunkCallback* /*callback*/) { 518 void SpdyProxyClientSocket::set_chunk_callback(ChunkCallback* /*callback*/) {
509 } 519 }
510 520
511 } // namespace net 521 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698