OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_PROVIDED_FILE_SYSTEM_INTERF
ACE_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_PROVIDED_FILE_SYSTEM_INTERF
ACE_H_ |
6 #define CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_PROVIDED_FILE_SYSTEM_INTERF
ACE_H_ | 6 #define CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_PROVIDED_FILE_SYSTEM_INTERF
ACE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
102 | 102 |
103 // Requests creating a directory. If |recursive| is passed, then all non | 103 // Requests creating a directory. If |recursive| is passed, then all non |
104 // existing directories on the path will be created. If |exclusive| is true, | 104 // existing directories on the path will be created. If |exclusive| is true, |
105 // then creating the directory will fail, if it already exists. | 105 // then creating the directory will fail, if it already exists. |
106 virtual void CreateDirectory( | 106 virtual void CreateDirectory( |
107 const base::FilePath& directory_path, | 107 const base::FilePath& directory_path, |
108 bool exclusive, | 108 bool exclusive, |
109 bool recursive, | 109 bool recursive, |
110 const fileapi::AsyncFileUtil::StatusCallback& callback) = 0; | 110 const fileapi::AsyncFileUtil::StatusCallback& callback) = 0; |
111 | 111 |
| 112 // Requests creating a file. If the entry already exists, then the |
| 113 // FILE_ERROR_EXISTS error must be returned. |
| 114 virtual void CreateFile( |
| 115 const base::FilePath& file_path, |
| 116 const fileapi::AsyncFileUtil::StatusCallback& callback) = 0; |
| 117 |
112 // Requests deleting a directory. If |recursive| is passed and the entry is | 118 // Requests deleting a directory. If |recursive| is passed and the entry is |
113 // a directory, then all contents of it (recursively) will be deleted too. | 119 // a directory, then all contents of it (recursively) will be deleted too. |
114 virtual void DeleteEntry( | 120 virtual void DeleteEntry( |
115 const base::FilePath& entry_path, | 121 const base::FilePath& entry_path, |
116 bool recursive, | 122 bool recursive, |
117 const fileapi::AsyncFileUtil::StatusCallback& callback) = 0; | 123 const fileapi::AsyncFileUtil::StatusCallback& callback) = 0; |
118 | 124 |
119 // Returns a provided file system info for this file system. | 125 // Returns a provided file system info for this file system. |
120 virtual const ProvidedFileSystemInfo& GetFileSystemInfo() const = 0; | 126 virtual const ProvidedFileSystemInfo& GetFileSystemInfo() const = 0; |
121 | 127 |
122 // Returns a request manager for the file system. | 128 // Returns a request manager for the file system. |
123 virtual RequestManager* GetRequestManager() = 0; | 129 virtual RequestManager* GetRequestManager() = 0; |
124 | 130 |
125 // Returns a weak pointer to this object. | 131 // Returns a weak pointer to this object. |
126 virtual base::WeakPtr<ProvidedFileSystemInterface> GetWeakPtr() = 0; | 132 virtual base::WeakPtr<ProvidedFileSystemInterface> GetWeakPtr() = 0; |
127 }; | 133 }; |
128 | 134 |
129 } // namespace file_system_provider | 135 } // namespace file_system_provider |
130 } // namespace chromeos | 136 } // namespace chromeos |
131 | 137 |
132 #endif // CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_PROVIDED_FILE_SYSTEM_INT
ERFACE_H_ | 138 #endif // CHROME_BROWSER_CHROMEOS_FILE_SYSTEM_PROVIDER_PROVIDED_FILE_SYSTEM_INT
ERFACE_H_ |
OLD | NEW |