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
3 // found in the LICENSE file.
5 #ifndef LIBRARIES_NACL_IO_MEMFS_MEM_FS_NODE_H_
6 #define LIBRARIES_NACL_IO_MEMFS_MEM_FS_NODE_H_
8 #include "nacl_io/node.h"
14 class MemFsNode : public Node {
16 explicit MemFsNode(Filesystem* filesystem);
22 // Normal read/write operations on a file
23 virtual Error Read(const HandleAttr& attr,
27 virtual Error Write(const HandleAttr& attr,
31 virtual Error FTruncate(off_t size);
34 void Resize(off_t size);
36 std::vector<char> data_;
40 } // namespace nacl_io
42 #endif // LIBRARIES_NACL_IO_MEMFS_MEM_FS_NODE_H_