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_DRIVE_DRIVE_FILE_SYSTEM_INTERFACE_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_INTERFACE_H_ |
6 #define CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_INTERFACE_H_ | 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_INTERFACE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
12 #include "chrome/browser/chromeos/drive/drive_cache.h" | 12 #include "chrome/browser/chromeos/drive/drive_cache.h" |
13 #include "chrome/browser/chromeos/drive/drive_resource_metadata.h" | 13 #include "chrome/browser/chromeos/drive/drive_resource_metadata.h" |
14 #include "chrome/browser/google_apis/gdata_operations.h" | 14 #include "chrome/browser/google_apis/gdata_operations.h" |
15 | 15 |
16 namespace gdata { | 16 namespace gdata { |
17 class DocumentEntry; | 17 class DocumentEntry; |
18 } | 18 } |
19 | 19 |
20 namespace drive { | 20 namespace drive { |
21 | 21 |
22 class DriveEntryProto; | 22 class DriveEntryProto; |
23 class DriveFileSystemObserver; | 23 class DriveFileSystemObserver; |
| 24 class DriveResourceMetadata; |
24 | 25 |
25 typedef std::vector<DriveEntryProto> DriveEntryProtoVector; | 26 typedef std::vector<DriveEntryProto> DriveEntryProtoVector; |
26 | 27 |
27 // Information about search result returned by Search Async callback. | 28 // Information about search result returned by Search Async callback. |
28 // This is data needed to create a file system entry that will be used by file | 29 // This is data needed to create a file system entry that will be used by file |
29 // browser. | 30 // browser. |
30 struct SearchResultInfo { | 31 struct SearchResultInfo { |
31 SearchResultInfo(const FilePath& in_path, bool in_is_directory) | 32 SearchResultInfo(const FilePath& in_path, bool in_is_directory) |
32 : path(in_path), | 33 : path(in_path), |
33 is_directory(in_is_directory) { | 34 is_directory(in_is_directory) { |
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
339 | 340 |
340 // Updates the data associated with the file referenced by |resource_id| and | 341 // Updates the data associated with the file referenced by |resource_id| and |
341 // |md5|. The data is copied from |file_content_path|. | 342 // |md5|. The data is copied from |file_content_path|. |
342 // | 343 // |
343 // |callback| will be called on the UI thread upon completion of operation. | 344 // |callback| will be called on the UI thread upon completion of operation. |
344 virtual void UpdateEntryData(const std::string& resource_id, | 345 virtual void UpdateEntryData(const std::string& resource_id, |
345 const std::string& md5, | 346 const std::string& md5, |
346 scoped_ptr<gdata::DocumentEntry> entry, | 347 scoped_ptr<gdata::DocumentEntry> entry, |
347 const FilePath& file_content_path, | 348 const FilePath& file_content_path, |
348 const base::Closure& callback) = 0; | 349 const base::Closure& callback) = 0; |
| 350 |
| 351 // Returns the resource metadata associated with the file system. |
| 352 virtual DriveResourceMetadata* GetResourceMetadata() = 0; |
349 }; | 353 }; |
350 | 354 |
351 } // namespace drive | 355 } // namespace drive |
352 | 356 |
353 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_INTERFACE_H_ | 357 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_INTERFACE_H_ |
OLD | NEW |