OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/socket/tcp_client_socket.h" | 5 #include "net/socket/tcp_client_socket.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/callback_helpers.h" | 9 #include "base/callback_helpers.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
232 } | 232 } |
233 | 233 |
234 void TCPClientSocket::SetOmniboxSpeculation() { | 234 void TCPClientSocket::SetOmniboxSpeculation() { |
235 use_history_.set_omnibox_speculation(); | 235 use_history_.set_omnibox_speculation(); |
236 } | 236 } |
237 | 237 |
238 bool TCPClientSocket::WasEverUsed() const { | 238 bool TCPClientSocket::WasEverUsed() const { |
239 return use_history_.was_used_to_convey_data(); | 239 return use_history_.was_used_to_convey_data(); |
240 } | 240 } |
241 | 241 |
242 bool TCPClientSocket::UsingTCPFastOpen() const { | |
243 return socket_->UsingTCPFastOpen(); | |
244 } | |
245 | |
246 void TCPClientSocket::EnableTCPFastOpenIfSupported() { | 242 void TCPClientSocket::EnableTCPFastOpenIfSupported() { |
247 socket_->EnableTCPFastOpenIfSupported(); | 243 socket_->EnableTCPFastOpenIfSupported(); |
248 } | 244 } |
249 | 245 |
250 bool TCPClientSocket::WasNpnNegotiated() const { | 246 bool TCPClientSocket::WasNpnNegotiated() const { |
251 return false; | 247 return false; |
252 } | 248 } |
253 | 249 |
254 NextProto TCPClientSocket::GetNegotiatedProtocol() const { | 250 NextProto TCPClientSocket::GetNegotiatedProtocol() const { |
255 return kProtoUnknown; | 251 return kProtoUnknown; |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
379 void TCPClientSocket::EmitTCPMetricsHistogramsOnDisconnect() { | 375 void TCPClientSocket::EmitTCPMetricsHistogramsOnDisconnect() { |
380 base::TimeDelta rtt; | 376 base::TimeDelta rtt; |
381 if (socket_->GetEstimatedRoundTripTime(&rtt)) { | 377 if (socket_->GetEstimatedRoundTripTime(&rtt)) { |
382 UMA_HISTOGRAM_CUSTOM_TIMES("Net.TcpRtt.AtDisconnect", rtt, | 378 UMA_HISTOGRAM_CUSTOM_TIMES("Net.TcpRtt.AtDisconnect", rtt, |
383 base::TimeDelta::FromMilliseconds(1), | 379 base::TimeDelta::FromMilliseconds(1), |
384 base::TimeDelta::FromMinutes(10), 100); | 380 base::TimeDelta::FromMinutes(10), 100); |
385 } | 381 } |
386 } | 382 } |
387 | 383 |
388 } // namespace net | 384 } // namespace net |
OLD | NEW |