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

Side by Side Diff: net/socket/tcp_client_socket.h

Issue 1215543003: Add UMA for the kernel's TCP RTT estimate. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add WARN_UNUSED_RESULT. Created 5 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
« no previous file with comments | « no previous file | net/socket/tcp_client_socket.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef NET_SOCKET_TCP_CLIENT_SOCKET_H_ 5 #ifndef NET_SOCKET_TCP_CLIENT_SOCKET_H_
6 #define NET_SOCKET_TCP_CLIENT_SOCKET_H_ 6 #define NET_SOCKET_TCP_CLIENT_SOCKET_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 89
90 // Helper used by Disconnect(), which disconnects minus resetting 90 // Helper used by Disconnect(), which disconnects minus resetting
91 // current_address_index_ and bind_address_. 91 // current_address_index_ and bind_address_.
92 void DoDisconnect(); 92 void DoDisconnect();
93 93
94 void DidCompleteConnect(int result); 94 void DidCompleteConnect(int result);
95 void DidCompleteReadWrite(const CompletionCallback& callback, int result); 95 void DidCompleteReadWrite(const CompletionCallback& callback, int result);
96 96
97 int OpenSocket(AddressFamily family); 97 int OpenSocket(AddressFamily family);
98 98
99 // Emits histograms for TCP metrics, at the time the socket is
100 // disconnected.
101 void EmitTCPMetricsHistogramsOnDisconnect();
102
99 scoped_ptr<TCPSocket> socket_; 103 scoped_ptr<TCPSocket> socket_;
100 104
101 // Local IP address and port we are bound to. Set to NULL if Bind() 105 // Local IP address and port we are bound to. Set to NULL if Bind()
102 // wasn't called (in that case OS chooses address/port). 106 // wasn't called (in that case OS chooses address/port).
103 scoped_ptr<IPEndPoint> bind_address_; 107 scoped_ptr<IPEndPoint> bind_address_;
104 108
105 // The list of addresses we should try in order to establish a connection. 109 // The list of addresses we should try in order to establish a connection.
106 AddressList addresses_; 110 AddressList addresses_;
107 111
108 // Where we are in above list. Set to -1 if uninitialized. 112 // Where we are in above list. Set to -1 if uninitialized.
(...skipping 14 matching lines...) Expand all
123 127
124 // Failed connection attempts made while trying to connect this socket. 128 // Failed connection attempts made while trying to connect this socket.
125 ConnectionAttempts connection_attempts_; 129 ConnectionAttempts connection_attempts_;
126 130
127 DISALLOW_COPY_AND_ASSIGN(TCPClientSocket); 131 DISALLOW_COPY_AND_ASSIGN(TCPClientSocket);
128 }; 132 };
129 133
130 } // namespace net 134 } // namespace net
131 135
132 #endif // NET_SOCKET_TCP_CLIENT_SOCKET_H_ 136 #endif // NET_SOCKET_TCP_CLIENT_SOCKET_H_
OLDNEW
« no previous file with comments | « no previous file | net/socket/tcp_client_socket.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698