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_DRIVE_FAKE_DRIVE_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_DRIVE_FAKE_DRIVE_SERVICE_H_ |
6 #define CHROME_BROWSER_DRIVE_FAKE_DRIVE_SERVICE_H_ | 6 #define CHROME_BROWSER_DRIVE_FAKE_DRIVE_SERVICE_H_ |
7 | 7 |
8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
9 #include "chrome/browser/drive/drive_service_interface.h" | 9 #include "chrome/browser/drive/drive_service_interface.h" |
10 | 10 |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 // the supported search query types. | 123 // the supported search query types. |
124 virtual google_apis::CancelCallback Search( | 124 virtual google_apis::CancelCallback Search( |
125 const std::string& search_query, | 125 const std::string& search_query, |
126 const google_apis::GetResourceListCallback& callback) OVERRIDE; | 126 const google_apis::GetResourceListCallback& callback) OVERRIDE; |
127 virtual google_apis::CancelCallback SearchByTitle( | 127 virtual google_apis::CancelCallback SearchByTitle( |
128 const std::string& title, | 128 const std::string& title, |
129 const std::string& directory_resource_id, | 129 const std::string& directory_resource_id, |
130 const google_apis::GetResourceListCallback& callback) OVERRIDE; | 130 const google_apis::GetResourceListCallback& callback) OVERRIDE; |
131 virtual google_apis::CancelCallback GetChangeList( | 131 virtual google_apis::CancelCallback GetChangeList( |
132 int64 start_changestamp, | 132 int64 start_changestamp, |
133 const google_apis::GetResourceListCallback& callback) OVERRIDE; | 133 const google_apis::ChangeListCallback& callback) OVERRIDE; |
134 virtual google_apis::CancelCallback GetRemainingChangeList( | 134 virtual google_apis::CancelCallback GetRemainingChangeList( |
135 const GURL& next_link, | 135 const GURL& next_link, |
136 const google_apis::GetResourceListCallback& callback) OVERRIDE; | 136 const google_apis::ChangeListCallback& callback) OVERRIDE; |
137 virtual google_apis::CancelCallback GetRemainingFileList( | 137 virtual google_apis::CancelCallback GetRemainingFileList( |
138 const GURL& next_link, | 138 const GURL& next_link, |
139 const google_apis::GetResourceListCallback& callback) OVERRIDE; | 139 const google_apis::GetResourceListCallback& callback) OVERRIDE; |
140 virtual google_apis::CancelCallback GetResourceEntry( | 140 virtual google_apis::CancelCallback GetResourceEntry( |
141 const std::string& resource_id, | 141 const std::string& resource_id, |
142 const google_apis::GetResourceEntryCallback& callback) OVERRIDE; | 142 const google_apis::GetResourceEntryCallback& callback) OVERRIDE; |
143 virtual google_apis::CancelCallback GetShareUrl( | 143 virtual google_apis::CancelCallback GetShareUrl( |
144 const std::string& resource_id, | 144 const std::string& resource_id, |
145 const GURL& embed_origin, | 145 const GURL& embed_origin, |
146 const google_apis::GetShareUrlCallback& callback) OVERRIDE; | 146 const google_apis::GetShareUrlCallback& callback) OVERRIDE; |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
304 // is between |start_offset| (inclusive) and |start_offset| + |max_results| | 304 // is between |start_offset| (inclusive) and |start_offset| + |max_results| |
305 // (exclusive). | 305 // (exclusive). |
306 // Increments *load_counter by 1 before it returns successfully. | 306 // Increments *load_counter by 1 before it returns successfully. |
307 void GetResourceListInternal( | 307 void GetResourceListInternal( |
308 int64 start_changestamp, | 308 int64 start_changestamp, |
309 const std::string& search_query, | 309 const std::string& search_query, |
310 const std::string& directory_resource_id, | 310 const std::string& directory_resource_id, |
311 int start_offset, | 311 int start_offset, |
312 int max_results, | 312 int max_results, |
313 int* load_counter, | 313 int* load_counter, |
314 const google_apis::GetResourceListCallback& callback); | 314 const google_apis::ChangeListCallback& callback); |
315 | 315 |
316 // Returns new upload session URL. | 316 // Returns new upload session URL. |
317 GURL GetNewUploadSessionUrl(); | 317 GURL GetNewUploadSessionUrl(); |
318 | 318 |
319 typedef std::map<std::string, EntryInfo*> EntryInfoMap; | 319 typedef std::map<std::string, EntryInfo*> EntryInfoMap; |
320 EntryInfoMap entries_; | 320 EntryInfoMap entries_; |
321 scoped_ptr<google_apis::AboutResource> about_resource_; | 321 scoped_ptr<google_apis::AboutResource> about_resource_; |
322 scoped_ptr<base::DictionaryValue> app_info_value_; | 322 scoped_ptr<base::DictionaryValue> app_info_value_; |
323 std::map<GURL, UploadSession> upload_sessions_; | 323 std::map<GURL, UploadSession> upload_sessions_; |
324 int64 published_date_seq_; | 324 int64 published_date_seq_; |
(...skipping 10 matching lines...) Expand all Loading... |
335 bool never_return_all_resource_list_; | 335 bool never_return_all_resource_list_; |
336 base::FilePath last_cancelled_file_; | 336 base::FilePath last_cancelled_file_; |
337 GURL share_url_base_; | 337 GURL share_url_base_; |
338 | 338 |
339 DISALLOW_COPY_AND_ASSIGN(FakeDriveService); | 339 DISALLOW_COPY_AND_ASSIGN(FakeDriveService); |
340 }; | 340 }; |
341 | 341 |
342 } // namespace drive | 342 } // namespace drive |
343 | 343 |
344 #endif // CHROME_BROWSER_DRIVE_FAKE_DRIVE_SERVICE_H_ | 344 #endif // CHROME_BROWSER_DRIVE_FAKE_DRIVE_SERVICE_H_ |
OLD | NEW |