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

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

Issue 1376473003: Notify NQE of TCP RTT values (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed rsleevi comments Created 4 years, 10 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef NET_SOCKET_TCP_SOCKET_WIN_H_ 5 #ifndef NET_SOCKET_TCP_SOCKET_WIN_H_
6 #define NET_SOCKET_TCP_SOCKET_WIN_H_ 6 #define NET_SOCKET_TCP_SOCKET_WIN_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <winsock2.h> 9 #include <winsock2.h>
10 10
11 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
12 #include "base/macros.h" 12 #include "base/macros.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "base/memory/scoped_ptr.h" 14 #include "base/memory/scoped_ptr.h"
15 #include "base/threading/non_thread_safe.h" 15 #include "base/threading/non_thread_safe.h"
16 #include "base/win/object_watcher.h" 16 #include "base/win/object_watcher.h"
17 #include "net/base/address_family.h" 17 #include "net/base/address_family.h"
18 #include "net/base/completion_callback.h" 18 #include "net/base/completion_callback.h"
19 #include "net/base/net_export.h" 19 #include "net/base/net_export.h"
20 #include "net/base/socket_performance_watcher.h"
20 #include "net/log/net_log.h" 21 #include "net/log/net_log.h"
21 22
22 namespace net { 23 namespace net {
23 24
24 class AddressList; 25 class AddressList;
25 class IOBuffer; 26 class IOBuffer;
26 class IPEndPoint; 27 class IPEndPoint;
27 28
28 class NET_EXPORT TCPSocketWin : NON_EXPORTED_BASE(public base::NonThreadSafe), 29 class NET_EXPORT TCPSocketWin : NON_EXPORTED_BASE(public base::NonThreadSafe),
29 public base::win::ObjectWatcher::Delegate { 30 public base::win::ObjectWatcher::Delegate {
30 public: 31 public:
31 TCPSocketWin(NetLog* net_log, const NetLog::Source& source); 32 TCPSocketWin(scoped_ptr<SocketPerformanceWatcher> socket_performance_watcher,
33 NetLog* net_log,
34 const NetLog::Source& source);
32 ~TCPSocketWin() override; 35 ~TCPSocketWin() override;
33 36
34 int Open(AddressFamily family); 37 int Open(AddressFamily family);
35 38
36 // Both AdoptConnectedSocket and AdoptListenSocket take ownership of an 39 // Both AdoptConnectedSocket and AdoptListenSocket take ownership of an
37 // existing socket. AdoptConnectedSocket takes an already connected 40 // existing socket. AdoptConnectedSocket takes an already connected
38 // socket. AdoptListenSocket takes a socket that is intended to accept 41 // socket. AdoptListenSocket takes a socket that is intended to accept
39 // connection. In some sense, AdoptListenSocket is more similar to Open. 42 // connection. In some sense, AdoptListenSocket is more similar to Open.
40 int AdoptConnectedSocket(SOCKET socket, const IPEndPoint& peer_address); 43 int AdoptConnectedSocket(SOCKET socket, const IPEndPoint& peer_address);
41 int AdoptListenSocket(SOCKET socket); 44 int AdoptListenSocket(SOCKET socket);
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 bool logging_multiple_connect_attempts_; 163 bool logging_multiple_connect_attempts_;
161 164
162 BoundNetLog net_log_; 165 BoundNetLog net_log_;
163 166
164 DISALLOW_COPY_AND_ASSIGN(TCPSocketWin); 167 DISALLOW_COPY_AND_ASSIGN(TCPSocketWin);
165 }; 168 };
166 169
167 } // namespace net 170 } // namespace net
168 171
169 #endif // NET_SOCKET_TCP_SOCKET_WIN_H_ 172 #endif // NET_SOCKET_TCP_SOCKET_WIN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698