OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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_GDATA_DRIVE_FILES_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_DRIVE_FILES_H_ |
6 #define CHROME_BROWSER_CHROMEOS_GDATA_DRIVE_FILES_H_ | 6 #define CHROME_BROWSER_CHROMEOS_GDATA_DRIVE_FILES_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
11 #include <vector> | 11 #include <vector> |
12 | 12 |
13 #include "base/callback.h" | 13 #include "base/callback.h" |
14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
15 #include "base/memory/weak_ptr.h" | 15 #include "base/memory/weak_ptr.h" |
16 #include "base/platform_file.h" | 16 #include "base/platform_file.h" |
17 #include "chrome/browser/chromeos/gdata/gdata_wapi_parser.h" | 17 #include "chrome/browser/chromeos/gdata/gdata_wapi_parser.h" |
18 | 18 |
19 namespace gdata { | 19 namespace gdata { |
20 | 20 |
21 class DriveDirectory; | 21 class DriveDirectory; |
22 class DriveDirectoryProto; | 22 class DriveDirectoryProto; |
23 class DriveEntryProto; | 23 class DriveEntryProto; |
24 class DriveFile; | 24 class DriveFile; |
25 class DriveResourceMetadata; | 25 class DriveResourceMetadata; |
26 class PlatformFileInfoProto; | 26 class PlatformFileInfoProto; |
27 | 27 |
28 // Used to read a directory from the file system. | 28 // Used to read a directory from the file system. |
29 // If |error| is not GDATA_FILE_OK, |entries| is set to NULL. | 29 // If |error| is not DRIVE_FILE_OK, |entries| is set to NULL. |
30 // |entries| are contents, both files and directories, of the directory. | 30 // |entries| are contents, both files and directories, of the directory. |
31 typedef std::vector<DriveEntryProto> DriveEntryProtoVector; | 31 typedef std::vector<DriveEntryProto> DriveEntryProtoVector; |
32 | 32 |
33 // Base class for representing files and directories in Drive virtual file | 33 // Base class for representing files and directories in Drive virtual file |
34 // system. | 34 // system. |
35 class DriveEntry { | 35 class DriveEntry { |
36 public: | 36 public: |
37 virtual ~DriveEntry(); | 37 virtual ~DriveEntry(); |
38 | 38 |
39 virtual DriveFile* AsDriveFile(); | 39 virtual DriveFile* AsDriveFile(); |
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
277 // Collection of children. | 277 // Collection of children. |
278 ChildMap child_files_; | 278 ChildMap child_files_; |
279 ChildMap child_directories_; | 279 ChildMap child_directories_; |
280 | 280 |
281 DISALLOW_COPY_AND_ASSIGN(DriveDirectory); | 281 DISALLOW_COPY_AND_ASSIGN(DriveDirectory); |
282 }; | 282 }; |
283 | 283 |
284 } // namespace gdata | 284 } // namespace gdata |
285 | 285 |
286 #endif // CHROME_BROWSER_CHROMEOS_GDATA_DRIVE_FILES_H_ | 286 #endif // CHROME_BROWSER_CHROMEOS_GDATA_DRIVE_FILES_H_ |
OLD | NEW |