OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_WEBSOCKET_TRANSPORT_CONNECT_SUB_JOB_H_ | 5 #ifndef NET_SOCKET_WEBSOCKET_TRANSPORT_CONNECT_SUB_JOB_H_ |
6 #define NET_SOCKET_WEBSOCKET_TRANSPORT_CONNECT_SUB_JOB_H_ | 6 #define NET_SOCKET_WEBSOCKET_TRANSPORT_CONNECT_SUB_JOB_H_ |
7 | 7 |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/macros.h" | 9 #include "base/macros.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 29 matching lines...) Expand all Loading... |
40 | 40 |
41 bool started() { return next_state_ != STATE_NONE; } | 41 bool started() { return next_state_ != STATE_NONE; } |
42 | 42 |
43 LoadState GetLoadState() const; | 43 LoadState GetLoadState() const; |
44 | 44 |
45 SubJobType type() const { return type_; } | 45 SubJobType type() const { return type_; } |
46 | 46 |
47 scoped_ptr<StreamSocket> PassSocket() { return transport_socket_.Pass(); } | 47 scoped_ptr<StreamSocket> PassSocket() { return transport_socket_.Pass(); } |
48 | 48 |
49 // Implementation of WebSocketEndpointLockManager::EndpointWaiter. | 49 // Implementation of WebSocketEndpointLockManager::EndpointWaiter. |
50 virtual void GotEndpointLock() OVERRIDE; | 50 virtual void GotEndpointLock() override; |
51 | 51 |
52 private: | 52 private: |
53 enum State { | 53 enum State { |
54 STATE_NONE, | 54 STATE_NONE, |
55 STATE_OBTAIN_LOCK, | 55 STATE_OBTAIN_LOCK, |
56 STATE_OBTAIN_LOCK_COMPLETE, | 56 STATE_OBTAIN_LOCK_COMPLETE, |
57 STATE_TRANSPORT_CONNECT, | 57 STATE_TRANSPORT_CONNECT, |
58 STATE_TRANSPORT_CONNECT_COMPLETE, | 58 STATE_TRANSPORT_CONNECT_COMPLETE, |
59 STATE_DONE, | 59 STATE_DONE, |
60 }; | 60 }; |
(...skipping 20 matching lines...) Expand all Loading... |
81 const SubJobType type_; | 81 const SubJobType type_; |
82 | 82 |
83 scoped_ptr<StreamSocket> transport_socket_; | 83 scoped_ptr<StreamSocket> transport_socket_; |
84 | 84 |
85 DISALLOW_COPY_AND_ASSIGN(WebSocketTransportConnectSubJob); | 85 DISALLOW_COPY_AND_ASSIGN(WebSocketTransportConnectSubJob); |
86 }; | 86 }; |
87 | 87 |
88 } // namespace net | 88 } // namespace net |
89 | 89 |
90 #endif // NET_SOCKET_WEBSOCKET_TRANSPORT_CONNECT_SUB_JOB_H_ | 90 #endif // NET_SOCKET_WEBSOCKET_TRANSPORT_CONNECT_SUB_JOB_H_ |
OLD | NEW |