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

Side by Side Diff: native_client_sdk/src/libraries/nacl_io/kernel_proxy.h

Issue 22587003: [NaCl SDK] Add UDP and TCP Sockets (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Running tests on package Created 7 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 LIBRARIES_NACL_IO_KERNEL_PROXY_H_ 5 #ifndef LIBRARIES_NACL_IO_KERNEL_PROXY_H_
6 #define LIBRARIES_NACL_IO_KERNEL_PROXY_H_ 6 #define LIBRARIES_NACL_IO_KERNEL_PROXY_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 10
11 #include "nacl_io/host_resolver.h" 11 #include "nacl_io/host_resolver.h"
12 #include "nacl_io/kernel_object.h" 12 #include "nacl_io/kernel_object.h"
13 #include "nacl_io/mount_factory.h" 13 #include "nacl_io/mount_factory.h"
14 #include "nacl_io/mount_socket.h"
14 #include "nacl_io/ossocket.h" 15 #include "nacl_io/ossocket.h"
15 #include "nacl_io/ostypes.h" 16 #include "nacl_io/ostypes.h"
16 #include "nacl_io/osutime.h" 17 #include "nacl_io/osutime.h"
17 18
18 struct timeval; 19 struct timeval;
19 20
20 namespace nacl_io { 21 namespace nacl_io {
21 22
22 class PepperInterface; 23 class PepperInterface;
23 24
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 int optname, 170 int optname,
170 const void* optval, 171 const void* optval,
171 socklen_t len); 172 socklen_t len);
172 virtual int shutdown(int fd, int how); 173 virtual int shutdown(int fd, int how);
173 virtual int socket(int domain, int type, int protocol); 174 virtual int socket(int domain, int type, int protocol);
174 virtual int socketpair(int domain, int type, int protocol, int* sv); 175 virtual int socketpair(int domain, int type, int protocol, int* sv);
175 #endif // PROVIDES_SOCKET_API 176 #endif // PROVIDES_SOCKET_API
176 177
177 protected: 178 protected:
178 MountFactoryMap_t factories_; 179 MountFactoryMap_t factories_;
180 sdk_util::ScopedRef<MountSocket> socket_mount_;
binji 2013/08/09 19:28:06 PROVIDES_SOCKET_API?
179 int dev_; 181 int dev_;
180 PepperInterface* ppapi_; 182 PepperInterface* ppapi_;
181 static KernelProxy *s_instance_; 183 static KernelProxy *s_instance_;
182 #ifdef PROVIDES_SOCKET_API 184 #ifdef PROVIDES_SOCKET_API
183 HostResolver host_resolver_; 185 HostResolver host_resolver_;
184 #endif 186 #endif
185 187
186 #ifdef PROVIDES_SOCKET_API 188 #ifdef PROVIDES_SOCKET_API
187 virtual int AcquireSocketHandle(int fd, ScopedKernelHandle* handle); 189 virtual int AcquireSocketHandle(int fd, ScopedKernelHandle* handle);
188 #endif 190 #endif
189 191
190 DISALLOW_COPY_AND_ASSIGN(KernelProxy); 192 DISALLOW_COPY_AND_ASSIGN(KernelProxy);
191 }; 193 };
192 194
193 } // namespace nacl_io 195 } // namespace nacl_io
194 196
195 #endif // LIBRARIES_NACL_IO_KERNEL_PROXY_H_ 197 #endif // LIBRARIES_NACL_IO_KERNEL_PROXY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698