OLD | NEW |
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_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/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 } | 166 } |
167 | 167 |
168 bool SpdyProxyClientSocket::WasEverUsed() const { | 168 bool SpdyProxyClientSocket::WasEverUsed() const { |
169 return was_ever_used_ || (spdy_stream_ && spdy_stream_->WasEverUsed()); | 169 return was_ever_used_ || (spdy_stream_ && spdy_stream_->WasEverUsed()); |
170 } | 170 } |
171 | 171 |
172 bool SpdyProxyClientSocket::UsingTCPFastOpen() const { | 172 bool SpdyProxyClientSocket::UsingTCPFastOpen() const { |
173 return false; | 173 return false; |
174 } | 174 } |
175 | 175 |
176 int64 SpdyProxyClientSocket::NumBytesRead() const { | |
177 return -1; | |
178 } | |
179 | |
180 base::TimeDelta SpdyProxyClientSocket::GetConnectTimeMicros() const { | |
181 return base::TimeDelta::FromMicroseconds(-1); | |
182 } | |
183 | |
184 bool SpdyProxyClientSocket::WasNpnNegotiated() const { | 176 bool SpdyProxyClientSocket::WasNpnNegotiated() const { |
185 return false; | 177 return false; |
186 } | 178 } |
187 | 179 |
188 NextProto SpdyProxyClientSocket::GetNegotiatedProtocol() const { | 180 NextProto SpdyProxyClientSocket::GetNegotiatedProtocol() const { |
189 return kProtoUnknown; | 181 return kProtoUnknown; |
190 } | 182 } |
191 | 183 |
192 bool SpdyProxyClientSocket::GetSSLInfo(SSLInfo* ssl_info) { | 184 bool SpdyProxyClientSocket::GetSSLInfo(SSLInfo* ssl_info) { |
193 bool was_npn_negotiated; | 185 bool was_npn_negotiated; |
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
600 } else if (!read_callback_.is_null()) { | 592 } else if (!read_callback_.is_null()) { |
601 // If we have a read_callback_, the we need to make sure we call it back. | 593 // If we have a read_callback_, the we need to make sure we call it back. |
602 OnDataReceived(NULL, 0); | 594 OnDataReceived(NULL, 0); |
603 } | 595 } |
604 // This may have been deleted by read_callback_, so check first. | 596 // This may have been deleted by read_callback_, so check first. |
605 if (weak_ptr && !write_callback.is_null()) | 597 if (weak_ptr && !write_callback.is_null()) |
606 write_callback.Run(ERR_CONNECTION_CLOSED); | 598 write_callback.Run(ERR_CONNECTION_CLOSED); |
607 } | 599 } |
608 | 600 |
609 } // namespace net | 601 } // namespace net |
OLD | NEW |