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

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

Issue 23498015: [NaCl SDK] Support non blocking TCP/UDP (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge emitter changes Created 7 years, 3 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 LIBRARIES_NACL_IO_MOUNT_SOCKET_H_ 5 #ifndef LIBRARIES_NACL_IO_MOUNT_STREAM_H_
6 #define LIBRARIES_NACL_IO_MOUNT_SOCKET_H_ 6 #define LIBRARIES_NACL_IO_MOUNT_STREAM_H_
7
8 #include "nacl_io/ossocket.h"
9 #ifdef PROVIDES_SOCKET_API
10 7
11 #include "nacl_io/mount.h" 8 #include "nacl_io/mount.h"
12 9
13 namespace nacl_io { 10 namespace nacl_io {
14 11
15 class MountSocket : public Mount { 12 // MountStreams provides a "mount point" for stream objects which do not
13 // provide a path, such as FDs returned by pipe, socket, and sockpair.
14
15 class MountStream : public Mount {
16 protected: 16 protected:
17 MountSocket(); 17 MountStream();
18 18
19 private: 19 private:
20 virtual Error Access(const Path& path, int a_mode); 20 virtual Error Access(const Path& path, int a_mode);
21 virtual Error Open(const Path& path, 21 virtual Error Open(const Path& path,
22 int o_flags, 22 int o_flags,
23 ScopedMountNode* out_node); 23 ScopedMountNode* out_node);
24 virtual Error Unlink(const Path& path); 24 virtual Error Unlink(const Path& path);
25 virtual Error Mkdir(const Path& path, int permissions); 25 virtual Error Mkdir(const Path& path, int permissions);
26 virtual Error Rmdir(const Path& path); 26 virtual Error Rmdir(const Path& path);
27 virtual Error Remove(const Path& path); 27 virtual Error Remove(const Path& path);
28 28
29 private: 29 private:
30 friend class KernelProxy; 30 friend class KernelProxy;
31 DISALLOW_COPY_AND_ASSIGN(MountSocket); 31 DISALLOW_COPY_AND_ASSIGN(MountStream);
32 }; 32 };
33 33
34 } // namespace nacl_io 34 } // namespace nacl_io
35 35
36 #endif // PROVIDES_SOCKET_API 36 #endif // LIBRARIES_NACL_IO_MOUNT_STREAM_H_
37 #endif // LIBRARIES_NACL_IO_MOUNT_SOCKET_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698