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_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_H_ |
6 #define CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_H_ | 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 20 matching lines...) Expand all Loading... |
31 class DriveServiceInterface; | 31 class DriveServiceInterface; |
32 class ResourceEntry; | 32 class ResourceEntry; |
33 } | 33 } |
34 | 34 |
35 namespace drive { | 35 namespace drive { |
36 | 36 |
37 class ChangeList; | 37 class ChangeList; |
38 class ChangeListLoader; | 38 class ChangeListLoader; |
39 class DriveCacheEntry; | 39 class DriveCacheEntry; |
40 class DriveResourceMetadata; | 40 class DriveResourceMetadata; |
41 class DriveScheduler; | |
42 class DriveWebAppsRegistry; | 41 class DriveWebAppsRegistry; |
43 class FileSystemObserver; | 42 class FileSystemObserver; |
| 43 class JobScheduler; |
44 | 44 |
45 // The production implementation of DriveFileSystemInterface. | 45 // The production implementation of DriveFileSystemInterface. |
46 class DriveFileSystem : public DriveFileSystemInterface, | 46 class DriveFileSystem : public DriveFileSystemInterface, |
47 public ChangeListLoaderObserver, | 47 public ChangeListLoaderObserver, |
48 public file_system::OperationObserver { | 48 public file_system::OperationObserver { |
49 public: | 49 public: |
50 DriveFileSystem(Profile* profile, | 50 DriveFileSystem(Profile* profile, |
51 DriveCache* cache, | 51 DriveCache* cache, |
52 google_apis::DriveServiceInterface* drive_service, | 52 google_apis::DriveServiceInterface* drive_service, |
53 DriveScheduler* scheduler, | 53 JobScheduler* scheduler, |
54 DriveWebAppsRegistry* webapps_registry, | 54 DriveWebAppsRegistry* webapps_registry, |
55 DriveResourceMetadata* resource_metadata, | 55 DriveResourceMetadata* resource_metadata, |
56 base::SequencedTaskRunner* blocking_task_runner); | 56 base::SequencedTaskRunner* blocking_task_runner); |
57 virtual ~DriveFileSystem(); | 57 virtual ~DriveFileSystem(); |
58 | 58 |
59 // DriveFileSystem overrides. | 59 // DriveFileSystem overrides. |
60 virtual void Initialize() OVERRIDE; | 60 virtual void Initialize() OVERRIDE; |
61 virtual void AddObserver(FileSystemObserver* observer) OVERRIDE; | 61 virtual void AddObserver(FileSystemObserver* observer) OVERRIDE; |
62 virtual void RemoveObserver(FileSystemObserver* observer) OVERRIDE; | 62 virtual void RemoveObserver(FileSystemObserver* observer) OVERRIDE; |
63 virtual void CheckForUpdates() OVERRIDE; | 63 virtual void CheckForUpdates() OVERRIDE; |
(...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
469 const OpenFileCallback& callback, | 469 const OpenFileCallback& callback, |
470 FileError error, | 470 FileError error, |
471 scoped_ptr<DriveEntryProto> entry_proto); | 471 scoped_ptr<DriveEntryProto> entry_proto); |
472 | 472 |
473 // The profile hosts the DriveFileSystem via DriveSystemService. | 473 // The profile hosts the DriveFileSystem via DriveSystemService. |
474 Profile* profile_; | 474 Profile* profile_; |
475 | 475 |
476 // Sub components owned by DriveSystemService. | 476 // Sub components owned by DriveSystemService. |
477 DriveCache* cache_; | 477 DriveCache* cache_; |
478 google_apis::DriveServiceInterface* drive_service_; | 478 google_apis::DriveServiceInterface* drive_service_; |
479 DriveScheduler* scheduler_; | 479 JobScheduler* scheduler_; |
480 DriveWebAppsRegistry* webapps_registry_; | 480 DriveWebAppsRegistry* webapps_registry_; |
481 DriveResourceMetadata* resource_metadata_; | 481 DriveResourceMetadata* resource_metadata_; |
482 | 482 |
483 // Time of the last update check. | 483 // Time of the last update check. |
484 base::Time last_update_check_time_; | 484 base::Time last_update_check_time_; |
485 | 485 |
486 // Error of the last update check. | 486 // Error of the last update check. |
487 FileError last_update_check_error_; | 487 FileError last_update_check_error_; |
488 | 488 |
489 // True if hosted documents should be hidden. | 489 // True if hosted documents should be hidden. |
(...skipping 19 matching lines...) Expand all Loading... |
509 // Note: This should remain the last member so it'll be destroyed and | 509 // Note: This should remain the last member so it'll be destroyed and |
510 // invalidate the weak pointers before any other members are destroyed. | 510 // invalidate the weak pointers before any other members are destroyed. |
511 base::WeakPtrFactory<DriveFileSystem> weak_ptr_factory_; | 511 base::WeakPtrFactory<DriveFileSystem> weak_ptr_factory_; |
512 | 512 |
513 DISALLOW_COPY_AND_ASSIGN(DriveFileSystem); | 513 DISALLOW_COPY_AND_ASSIGN(DriveFileSystem); |
514 }; | 514 }; |
515 | 515 |
516 } // namespace drive | 516 } // namespace drive |
517 | 517 |
518 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_H_ | 518 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_DRIVE_FILE_SYSTEM_H_ |
OLD | NEW |