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
3 // found in the LICENSE file.
5 #ifndef STORAGE_COMMON_FILEAPI_FILE_SYSTEM_TYPES_H_
6 #define STORAGE_COMMON_FILEAPI_FILE_SYSTEM_TYPES_H_
8 #include "third_party/WebKit/public/platform/WebFileSystemType.h"
13 // Indicates uninitialized or invalid filesystem type.
14 kFileSystemTypeUnknown = -1,
16 // ------------------------------------------------------------------------
17 // Public FileSystem types, that are embedded in filesystem: URL and exposed
18 // to WebKit/renderer. Both Chrome and WebKit know how to handle these types.
20 // Following two types are for TEMPORARY or PERSISTENT filesystems that
21 // can be used by webapps via standard app-facing API
22 // as defined in File API: Directories and System.
23 // http://www.w3.org/TR/file-system-api/#temporary-vs.-persistent-storage
24 // They are sandboxed filesystems; all the files in the filesystems are
25 // placed under the profile directory with path obfuscation and quota
27 kFileSystemTypeTemporary = blink::WebFileSystemTypeTemporary,
28 kFileSystemTypePersistent = blink::WebFileSystemTypePersistent,
30 // Indicates non-sandboxed isolated filesystem.
31 kFileSystemTypeIsolated = blink::WebFileSystemTypeIsolated,
33 // Indicates filesystems that are mounted externally via
34 // ExternalMountPoints with a well-known mount name. The mounted
35 // filesystems can be sandboxed or non-sandboxed. (E.g. Chrome OS mounts
36 // non-sandboxed removable media folder with a name 'removable', while
37 // chrome.syncFileSystem mounts a sandboxed filesystem with a name
39 kFileSystemTypeExternal = blink::WebFileSystemTypeExternal,
41 // ------------------------------------------------------------------------
42 // Marks the beginning of internal type enum. (This is not the actual fs type)
43 kFileSystemInternalTypeEnumStart = 99,
45 // Private FileSystem types, that should not appear in filesystem: URL as
46 // WebKit has no idea how to handle those types.
48 // One can register (mount) a new file system with a private file system type
49 // using IsolatedContext. Files in such file systems can be accessed via
50 // either Isolated or External public file system types (depending on
51 // how the file system is registered).
52 // See the comments for IsolatedContext and/or FileSystemURL for more details.
54 // Should be used only for testing.
57 // Indicates a local filesystem where we can access files using native
59 kFileSystemTypeNativeLocal,
61 // Indicates a local filesystem where we can access files using native
62 // local path, but with restricted access.
63 // Restricted native local file system is in read-only mode.
64 kFileSystemTypeRestrictedNativeLocal,
66 // Indicates a transient, isolated file system for dragged files (which could
67 // contain multiple dragged paths in the virtual root).
68 kFileSystemTypeDragged,
70 // Indicates media filesystem which we can access with same manner to
71 // regular filesystem.
72 kFileSystemTypeNativeMedia,
74 // Indicates media filesystem to which we need special protocol to access,
75 // such as MTP or PTP.
76 kFileSystemTypeDeviceMedia,
78 // Indicates a Picasa virtual filesystem provided by Media Galleries API.
79 kFileSystemTypePicasa,
81 // Indicates a synthetic iTunes filesystem.
82 kFileSystemTypeItunes,
84 // Indicates a synthetic iPhoto filesystem.
85 kFileSystemTypeIphoto,
87 // Indicates a Drive filesystem which provides access to Google Drive.
90 // Indicates a Syncable sandboxed filesystem which can be backed by a
91 // cloud storage service.
92 kFileSystemTypeSyncable,
94 // Indicates a special filesystem type for internal file sync operation
95 // for Syncable sandboxed filesystems. The file system is overlayed, i.e.
96 // points to the same sandboxed filesystem as that of kFileSystemTypeSyncable,
97 // but the changes made with this filesystem type are not recorded for
99 kFileSystemTypeSyncableForInternalSync,
101 // Indicates an external filesystem accessible by file paths from platform
102 // Apps. As of writing, on non Chrome OS platform, this is merely a
103 // kFileSystemTypeNativeLocal. On Chrome OS, the path is parsed by
104 // the handlers of kFileSystemTypeExternal.
105 kFileSystemTypeNativeForPlatformApp,
107 // Indicates an isolated filesystem which is supposed to contain one
108 // temporary which is supposed to go away when the last reference of
109 // its snapshot is dropped.
110 // This type is useful for creating a blob reference for a temporary
111 // file which must go away when the blob's last reference is dropped.
112 kFileSystemTypeForTransientFile,
114 // Sandboxed private filesystem. This filesystem cannot be opened
115 // via regular OpenFileSystem, and provides private filesystem space for
116 // given identifier in each origin.
117 kFileSystemTypePluginPrivate,
119 // A filesystem that is mounted via the Privet storage protocol.
120 kFileSystemTypeCloudDevice,
122 // A filesystem that is mounted via the FileSystemProvider API.
123 kFileSystemTypeProvided,
125 // A media filesystem such as MTP or PTP, mounted as a file storage not
126 // limited to media files.
127 kFileSystemTypeDeviceMediaAsFileStorage,
129 // --------------------------------------------------------------------
130 // Marks the end of internal type enum. (This is not the actual fs type)
131 // New internal filesystem types must be added above this line.
132 kFileSystemInternalTypeEnumEnd,
135 } // namespace storage
137 #endif // STORAGE_COMMON_FILEAPI_FILE_SYSTEM_TYPES_H_