Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(640)

Side by Side Diff: chrome/browser/chromeos/gdata/gdata_file_system_interface.h

Issue 10834115: Drive: Mount/Unmount GoogleDrive on Files App when the file system is mounted/unmounted. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_GDATA_FILE_SYSTEM_INTERFACE_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_INTERFACE_H_
6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_INTERFACE_H_ 6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_INTERFACE_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 // Triggered when the file system is initially loaded. 100 // Triggered when the file system is initially loaded.
101 virtual void OnInitialLoadFinished() {} 101 virtual void OnInitialLoadFinished() {}
102 102
103 // Triggered when a document feed is fetched. |num_accumulated_entries| 103 // Triggered when a document feed is fetched. |num_accumulated_entries|
104 // tells the number of entries fetched so far. 104 // tells the number of entries fetched so far.
105 virtual void OnDocumentFeedFetched(int num_accumulated_entries) {} 105 virtual void OnDocumentFeedFetched(int num_accumulated_entries) {}
106 106
107 // Triggered when the feed from the server is loaded. 107 // Triggered when the feed from the server is loaded.
108 virtual void OnFeedFromServerLoaded() {} 108 virtual void OnFeedFromServerLoaded() {}
109 109
110 // Triggered when the file system is mounted.
111 virtual void OnFileSystemMounted() {}
112 // Triggered when the file system is getting unmounted.
113 virtual void OnFileSystemUnmounting() {}
114
110 protected: 115 protected:
111 virtual ~Observer() {} 116 virtual ~Observer() {}
112 }; 117 };
113 118
114 // Initializes the object. This function should be called before any 119 // Initializes the object. This function should be called before any
115 // other functions. 120 // other functions.
116 virtual void Initialize() = 0; 121 virtual void Initialize() = 0;
117 122
118 // Adds and removes the observer. 123 // Adds and removes the observer.
119 virtual void AddObserver(Observer* observer) = 0; 124 virtual void AddObserver(Observer* observer) = 0;
120 virtual void RemoveObserver(Observer* observer) = 0; 125 virtual void RemoveObserver(Observer* observer) = 0;
121 126
122 // Starts and stops periodic updates. 127 // Starts and stops periodic updates.
123 virtual void StartUpdates() = 0; 128 virtual void StartUpdates() = 0;
124 virtual void StopUpdates() = 0; 129 virtual void StopUpdates() = 0;
125 130
131 // Notifies the file system is mounted or getting unmounted.
satorux1 2012/08/03 17:28:56 Add separate comments // Notifies the file system
yoshiki 2012/08/03 18:15:08 Done.
132 virtual void NotifyFileSystemMounted() = 0;
133 virtual void NotifyFileSystemUnmounting() = 0;
satorux1 2012/08/03 17:28:56 NotifyFileSystemToBeUnmounted
yoshiki 2012/08/03 18:15:08 Done.
134
126 // Checks for updates on the server. 135 // Checks for updates on the server.
127 virtual void CheckForUpdates() = 0; 136 virtual void CheckForUpdates() = 0;
128 137
129 // Finds an entry (file or directory) by using |resource_id|. This call 138 // Finds an entry (file or directory) by using |resource_id|. This call
130 // does not initiate content refreshing. 139 // does not initiate content refreshing.
131 // 140 //
132 // Can be called from UI/IO thread. |callback| is run on the calling thread. 141 // Can be called from UI/IO thread. |callback| is run on the calling thread.
133 virtual void GetEntryInfoByResourceId( 142 virtual void GetEntryInfoByResourceId(
134 const std::string& resource_id, 143 const std::string& resource_id,
135 const GetEntryInfoWithFilePathCallback& callback) = 0; 144 const GetEntryInfoWithFilePathCallback& callback) = 0;
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after
341 const FilePath& virtual_dir_path, 350 const FilePath& virtual_dir_path,
342 scoped_ptr<DocumentEntry> entry, 351 scoped_ptr<DocumentEntry> entry,
343 const FilePath& file_content_path, 352 const FilePath& file_content_path,
344 GDataCache::FileOperationType cache_operation, 353 GDataCache::FileOperationType cache_operation,
345 const base::Closure& callback) = 0; 354 const base::Closure& callback) = 0;
346 }; 355 };
347 356
348 } // namespace gdata 357 } // namespace gdata
349 358
350 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_INTERFACE_H_ 359 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_INTERFACE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698