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

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

Issue 19717004: [NaCl SDK] Add nacl_io and sdk_util namespaces. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix bad copyright in mount_mem Created 7 years, 5 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_MOUNT_HTML5FS_NODE_H_ 5 #ifndef LIBRARIES_NACL_IO_MOUNT_HTML5FS_NODE_H_
6 #define LIBRARIES_NACL_IO_MOUNT_HTML5FS_NODE_H_ 6 #define LIBRARIES_NACL_IO_MOUNT_HTML5FS_NODE_H_
7 7
8 #include <ppapi/c/pp_resource.h> 8 #include <ppapi/c/pp_resource.h>
9 #include "nacl_io/mount_node.h" 9 #include "nacl_io/mount_node.h"
10 10
11 namespace nacl_io {
12
11 class MountHtml5Fs; 13 class MountHtml5Fs;
12 14
13 class MountNodeHtml5Fs : public MountNode { 15 class MountNodeHtml5Fs : public MountNode {
14 public: 16 public:
15 // Normal OS operations on a node (file), can be called by the kernel 17 // Normal OS operations on a node (file), can be called by the kernel
16 // directly so it must lock and unlock appropriately. These functions 18 // directly so it must lock and unlock appropriately. These functions
17 // must not be called by the mount. 19 // must not be called by the mount.
18 virtual Error FSync(); 20 virtual Error FSync();
19 virtual Error GetDents(size_t offs, 21 virtual Error GetDents(size_t offs,
20 struct dirent* pdir, 22 struct dirent* pdir,
(...skipping 21 matching lines...) Expand all
42 PP_Resource fileio_resource_; // 0 if the file is a directory. 44 PP_Resource fileio_resource_; // 0 if the file is a directory.
43 45
44 // Returns true if this node is a directory. 46 // Returns true if this node is a directory.
45 bool IsDirectory() const { 47 bool IsDirectory() const {
46 return !fileio_resource_; 48 return !fileio_resource_;
47 } 49 }
48 50
49 friend class MountHtml5Fs; 51 friend class MountHtml5Fs;
50 }; 52 };
51 53
54 } // namespace nacl_io
55
52 #endif // LIBRARIES_NACL_IO_MOUNT_HTML5FS_NODE_H_ 56 #endif // LIBRARIES_NACL_IO_MOUNT_HTML5FS_NODE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698