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

Side by Side Diff: chrome/browser/chromeos/drive/change_list_loader.h

Issue 278273002: drive: Change the return type of ResourceMetadata's methods to FileError (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/chromeos/drive/change_list_loader.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_DRIVE_CHANGE_LIST_LOADER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_CHANGE_LIST_LOADER_H_
6 #define CHROME_BROWSER_CHROMEOS_DRIVE_CHANGE_LIST_LOADER_H_ 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_CHANGE_LIST_LOADER_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 // starts loading from the server, and runs |callback| to tell the result to 156 // starts loading from the server, and runs |callback| to tell the result to
157 // the caller when it is finished. 157 // the caller when it is finished.
158 // 158 //
159 // |callback| must not be null. 159 // |callback| must not be null.
160 void LoadIfNeeded(const FileOperationCallback& callback); 160 void LoadIfNeeded(const FileOperationCallback& callback);
161 161
162 private: 162 private:
163 // Starts the resource metadata loading and calls |callback| when it's done. 163 // Starts the resource metadata loading and calls |callback| when it's done.
164 void Load(const FileOperationCallback& callback); 164 void Load(const FileOperationCallback& callback);
165 void LoadAfterGetLargestChangestamp(bool is_initial_load, 165 void LoadAfterGetLargestChangestamp(bool is_initial_load,
166 int64 local_changestamp); 166 const int64* local_changestamp,
167 FileError error);
167 void LoadAfterGetAboutResource( 168 void LoadAfterGetAboutResource(
168 int64 local_changestamp, 169 int64 local_changestamp,
169 google_apis::GDataErrorCode status, 170 google_apis::GDataErrorCode status,
170 scoped_ptr<google_apis::AboutResource> about_resource); 171 scoped_ptr<google_apis::AboutResource> about_resource);
171 172
172 // Part of Load(). 173 // Part of Load().
173 // This function should be called when the change list load is complete. 174 // This function should be called when the change list load is complete.
174 // Flushes the callbacks for change list loading and all directory loading. 175 // Flushes the callbacks for change list loading and all directory loading.
175 void OnChangeListLoadComplete(FileError error); 176 void OnChangeListLoadComplete(FileError error);
176 177
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 // Note: This should remain the last member so it'll be destroyed and 218 // Note: This should remain the last member so it'll be destroyed and
218 // invalidate its weak pointers before any other members are destroyed. 219 // invalidate its weak pointers before any other members are destroyed.
219 base::WeakPtrFactory<ChangeListLoader> weak_ptr_factory_; 220 base::WeakPtrFactory<ChangeListLoader> weak_ptr_factory_;
220 DISALLOW_COPY_AND_ASSIGN(ChangeListLoader); 221 DISALLOW_COPY_AND_ASSIGN(ChangeListLoader);
221 }; 222 };
222 223
223 } // namespace internal 224 } // namespace internal
224 } // namespace drive 225 } // namespace drive
225 226
226 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_CHANGE_LIST_LOADER_H_ 227 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_CHANGE_LIST_LOADER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/drive/change_list_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698