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

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

Issue 12166002: Cleanup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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_MOUNTS_MOUNT_HTML5FS_NODE_H_ 5 #ifndef LIBRARIES_NACL_MOUNTS_MOUNT_HTML5FS_NODE_H_
6 #define LIBRARIES_NACL_MOUNTS_MOUNT_HTML5FS_NODE_H_ 6 #define LIBRARIES_NACL_MOUNTS_MOUNT_HTML5FS_NODE_H_
7 7
8 #include <ppapi/c/pp_resource.h> 8 #include <ppapi/c/pp_resource.h>
9 #include "nacl_mounts/mount_node.h" 9 #include "nacl_mounts/mount_node.h"
10 10
11 class MountHtml5Fs; 11 class MountHtml5Fs;
12 12
13 class MountNodeHtml5Fs : public MountNode { 13 class MountNodeHtml5Fs : public MountNode {
14 public: 14 public:
15 // Normal OS operations on a node (file), can be called by the kernel 15 // Normal OS operations on a node (file), can be called by the kernel
16 // directly so it must lock and unlock appropriately. These functions 16 // directly so it must lock and unlock appropriately. These functions
17 // must not be called by the mount. 17 // must not be called by the mount.
18 virtual int FSync(); 18 virtual int FSync();
19 virtual int GetDents(size_t offs, struct dirent* pdir, size_t count); 19 virtual int GetDents(size_t offs, struct dirent* pdir, size_t count);
20 virtual int GetStat(struct stat* stat); 20 virtual int GetStat(struct stat* stat);
21 virtual int Read(size_t offs, void* buf, size_t count); 21 virtual int Read(size_t offs, void* buf, size_t count);
22 virtual int Truncate(size_t size); 22 virtual int Truncate(size_t size);
23 virtual int Write(size_t offs, const void* buf, size_t count); 23 virtual int Write(size_t offs, const void* buf, size_t count);
24 24
25 virtual size_t GetSize(); 25 virtual size_t GetSize();
26 26
27 protected: 27 protected:
28 MountNodeHtml5Fs(Mount* mount, int ino, int dev, PP_Resource fileref); 28 MountNodeHtml5Fs(Mount* mount, PP_Resource fileref);
29 virtual bool Init(int mode, short uid, short gid); 29 virtual bool Init(int mode);
binji 2013/02/02 00:04:44 int perm
noelallen1 2013/02/04 18:40:06 Done.
30 virtual int Close(); 30 virtual void Destroy();
31 31
32 private: 32 private:
33 PP_Resource fileref_resource_; 33 PP_Resource fileref_resource_;
34 PP_Resource fileio_resource_; 34 PP_Resource fileio_resource_;
35 35
36 friend class MountHtml5Fs; 36 friend class MountHtml5Fs;
37 }; 37 };
38 38
39 #endif // LIBRARIES_NACL_MOUNTS_MOUNT_HTML5FS_NODE_H_ 39 #endif // LIBRARIES_NACL_MOUNTS_MOUNT_HTML5FS_NODE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698