OLD | NEW |
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 PPAPI_PROXY_TCP_SOCKET_RESOURCE_BASE_H_ | 5 #ifndef PPAPI_PROXY_TCP_SOCKET_RESOURCE_BASE_H_ |
6 #define PPAPI_PROXY_TCP_SOCKET_RESOURCE_BASE_H_ | 6 #define PPAPI_PROXY_TCP_SOCKET_RESOURCE_BASE_H_ |
7 | 7 |
8 #include <queue> | 8 #include <queue> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 scoped_refptr<TrackedCallback> callback); | 88 scoped_refptr<TrackedCallback> callback); |
89 int32_t WriteImpl(const char* buffer, | 89 int32_t WriteImpl(const char* buffer, |
90 int32_t bytes_to_write, | 90 int32_t bytes_to_write, |
91 scoped_refptr<TrackedCallback> callback); | 91 scoped_refptr<TrackedCallback> callback); |
92 int32_t ListenImpl(int32_t backlog, scoped_refptr<TrackedCallback> callback); | 92 int32_t ListenImpl(int32_t backlog, scoped_refptr<TrackedCallback> callback); |
93 int32_t AcceptImpl(PP_Resource* accepted_tcp_socket, | 93 int32_t AcceptImpl(PP_Resource* accepted_tcp_socket, |
94 scoped_refptr<TrackedCallback> callback); | 94 scoped_refptr<TrackedCallback> callback); |
95 void CloseImpl(); | 95 void CloseImpl(); |
96 int32_t SetOptionImpl(PP_TCPSocket_Option name, | 96 int32_t SetOptionImpl(PP_TCPSocket_Option name, |
97 const PP_Var& value, | 97 const PP_Var& value, |
| 98 bool check_connect_state, |
98 scoped_refptr<TrackedCallback> callback); | 99 scoped_refptr<TrackedCallback> callback); |
99 | 100 |
100 void PostAbortIfNecessary(scoped_refptr<TrackedCallback>* callback); | 101 void PostAbortIfNecessary(scoped_refptr<TrackedCallback>* callback); |
101 | 102 |
102 // IPC message handlers. | 103 // IPC message handlers. |
103 void OnPluginMsgBindReply(const ResourceMessageReplyParams& params, | 104 void OnPluginMsgBindReply(const ResourceMessageReplyParams& params, |
104 const PP_NetAddress_Private& local_addr); | 105 const PP_NetAddress_Private& local_addr); |
105 void OnPluginMsgConnectReply(const ResourceMessageReplyParams& params, | 106 void OnPluginMsgConnectReply(const ResourceMessageReplyParams& params, |
106 const PP_NetAddress_Private& local_addr, | 107 const PP_NetAddress_Private& local_addr, |
107 const PP_NetAddress_Private& remote_addr); | 108 const PP_NetAddress_Private& remote_addr); |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 | 147 |
147 TCPSocketVersion version_; | 148 TCPSocketVersion version_; |
148 | 149 |
149 DISALLOW_COPY_AND_ASSIGN(TCPSocketResourceBase); | 150 DISALLOW_COPY_AND_ASSIGN(TCPSocketResourceBase); |
150 }; | 151 }; |
151 | 152 |
152 } // namespace proxy | 153 } // namespace proxy |
153 } // namespace ppapi | 154 } // namespace ppapi |
154 | 155 |
155 #endif // PPAPI_PROXY_TCP_SOCKET_RESOURCE_BASE_H_ | 156 #endif // PPAPI_PROXY_TCP_SOCKET_RESOURCE_BASE_H_ |
OLD | NEW |