OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 BASE_FILE_UTIL_PROXY_H_ | 5 #ifndef BASE_FILE_UTIL_PROXY_H_ |
6 #define BASE_FILE_UTIL_PROXY_H_ | 6 #define BASE_FILE_UTIL_PROXY_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
11 #include "base/file_path.h" | 11 #include "base/file_path.h" |
12 #include "base/file_util.h" | 12 #include "base/file_util.h" |
13 #include "base/platform_file.h" | 13 #include "base/platform_file.h" |
14 #include "base/ref_counted.h" | 14 #include "base/ref_counted.h" |
15 #include "base/tracked_objects.h" | 15 #include "base/tracked_objects.h" |
16 | 16 |
17 namespace file_util { | 17 namespace file_util { |
18 struct FileInfo; | 18 struct FileInfo; |
19 } | 19 } |
20 | 20 |
21 namespace base { | 21 namespace base { |
22 | 22 |
23 namespace file_util_proxy { | 23 namespace file_util_proxy { |
24 // Holds metadata for file or directory entry. | 24 |
| 25 // Holds metadata for file or directory entry. |
25 struct Entry { | 26 struct Entry { |
26 FilePath::StringType name; | 27 FilePath::StringType name; |
27 bool isDirectory; | 28 bool is_directory; |
28 }; | 29 }; |
| 30 |
29 } // namespace file_util_proxy | 31 } // namespace file_util_proxy |
30 | 32 |
31 class MessageLoopProxy; | 33 class MessageLoopProxy; |
32 | 34 |
33 // This class provides asynchronous access to common file routines. | 35 // This class provides asynchronous access to common file routines. |
34 class FileUtilProxy { | 36 class FileUtilProxy { |
35 public: | 37 public: |
36 // This callback is used by methods that report only an error code. It is | 38 // This callback is used by methods that report only an error code. It is |
37 // valid to pass NULL as the callback parameter to any function that takes a | 39 // valid to pass NULL as the callback parameter to any function that takes a |
38 // StatusCallback, in which case the operation will complete silently. | 40 // StatusCallback, in which case the operation will complete silently. |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
119 const FilePath& file_path, | 121 const FilePath& file_path, |
120 StatusCallback* callback); | 122 StatusCallback* callback); |
121 | 123 |
122 private: | 124 private: |
123 DISALLOW_IMPLICIT_CONSTRUCTORS(FileUtilProxy); | 125 DISALLOW_IMPLICIT_CONSTRUCTORS(FileUtilProxy); |
124 }; | 126 }; |
125 | 127 |
126 } // namespace base | 128 } // namespace base |
127 | 129 |
128 #endif // BASE_FILE_UTIL_PROXY_H_ | 130 #endif // BASE_FILE_UTIL_PROXY_H_ |
OLD | NEW |