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

Side by Side Diff: native_client_sdk/src/libraries/nacl_io/httpfs/http_fs.h

Issue 320983002: [NaCl SDK] nacl_io: Allows subtree of html5fs to be mounted. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 2013 The Chromium Authors. All rights reserved. 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 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_HTTPFS_HTTP_FS_H_ 5 #ifndef LIBRARIES_NACL_IO_HTTPFS_HTTP_FS_H_
6 #define LIBRARIES_NACL_IO_HTTPFS_HTTP_FS_H_ 6 #define LIBRARIES_NACL_IO_HTTPFS_HTTP_FS_H_
7 7
8 #include <string> 8 #include <string>
9 #include "nacl_io/filesystem.h" 9 #include "nacl_io/filesystem.h"
10 #include "nacl_io/pepper_interface.h" 10 #include "nacl_io/pepper_interface.h"
(...skipping 24 matching lines...) Expand all
35 35
36 virtual Error Init(const FsInitArgs& args); 36 virtual Error Init(const FsInitArgs& args);
37 virtual void Destroy(); 37 virtual void Destroy();
38 Error FindOrCreateDir(const Path& path, ScopedNode* out_node); 38 Error FindOrCreateDir(const Path& path, ScopedNode* out_node);
39 Error LoadManifest(const std::string& path, char** out_manifest); 39 Error LoadManifest(const std::string& path, char** out_manifest);
40 Error ParseManifest(const char* text); 40 Error ParseManifest(const char* text);
41 41
42 NodeMap_t* GetNodeCacheForTesting() { return &node_cache_; } 42 NodeMap_t* GetNodeCacheForTesting() { return &node_cache_; }
43 43
44 private: 44 private:
45
45 // Gets the URL to fetch for |path|. 46 // Gets the URL to fetch for |path|.
46 // |path| is relative to the mount point for the HTTP filesystem. 47 // |path| is relative to the mount point for the HTTP filesystem.
47 std::string MakeUrl(const Path& path); 48 std::string MakeUrl(const Path& path);
48 49
49 std::string url_root_; 50 std::string url_root_;
50 StringMap_t headers_; 51 StringMap_t headers_;
51 NodeMap_t node_cache_; 52 NodeMap_t node_cache_;
52 bool allow_cors_; 53 bool allow_cors_;
53 bool allow_credentials_; 54 bool allow_credentials_;
54 bool cache_stat_; 55 bool cache_stat_;
55 bool cache_content_; 56 bool cache_content_;
56 57
57 friend class TypedFsFactory<HttpFs>; 58 friend class TypedFsFactory<HttpFs>;
58 friend class HttpFsNode; 59 friend class HttpFsNode;
59 }; 60 };
60 61
61 } // namespace nacl_io 62 } // namespace nacl_io
62 63
63 #endif // LIBRARIES_NACL_IO_HTTPFS_HTTP_FS_H_ 64 #endif // LIBRARIES_NACL_IO_HTTPFS_HTTP_FS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698