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 "base/values.h" | 9 #include "base/values.h" |
10 #include "chrome/browser/drive/drive_service_interface.h" | 10 #include "chrome/browser/drive/drive_service_interface.h" |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 // Returns the number of times the resource list is successfully loaded by | 61 // Returns the number of times the resource list is successfully loaded by |
62 // GetResourceListInDirectory(). | 62 // GetResourceListInDirectory(). |
63 int directory_load_count() const { return directory_load_count_; } | 63 int directory_load_count() const { return directory_load_count_; } |
64 | 64 |
65 // Returns the number of times the about resource is successfully loaded | 65 // Returns the number of times the about resource is successfully loaded |
66 // by GetAboutResource(). | 66 // by GetAboutResource(). |
67 int about_resource_load_count() const { | 67 int about_resource_load_count() const { |
68 return about_resource_load_count_; | 68 return about_resource_load_count_; |
69 } | 69 } |
70 | 70 |
| 71 // Returns the number of times the app list is successfully loaded by |
| 72 // GetAppList(). |
| 73 int app_list_load_count() const { return app_list_load_count_; } |
| 74 |
71 // Returns the file path whose request is cancelled just before this method | 75 // Returns the file path whose request is cancelled just before this method |
72 // invocation. | 76 // invocation. |
73 const base::FilePath& last_cancelled_file() const { | 77 const base::FilePath& last_cancelled_file() const { |
74 return last_cancelled_file_; | 78 return last_cancelled_file_; |
75 } | 79 } |
76 | 80 |
77 // Returns the (fake) URL for the link. | 81 // Returns the (fake) URL for the link. |
78 static GURL GetFakeLinkUrl(const std::string& resource_id); | 82 static GURL GetFakeLinkUrl(const std::string& resource_id); |
79 | 83 |
80 // DriveServiceInterface Overrides | 84 // DriveServiceInterface Overrides |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
265 std::map<GURL, UploadSession> upload_sessions_; | 269 std::map<GURL, UploadSession> upload_sessions_; |
266 int64 largest_changestamp_; | 270 int64 largest_changestamp_; |
267 int64 published_date_seq_; | 271 int64 published_date_seq_; |
268 int64 next_upload_sequence_number_; | 272 int64 next_upload_sequence_number_; |
269 int default_max_results_; | 273 int default_max_results_; |
270 int resource_id_count_; | 274 int resource_id_count_; |
271 int resource_list_load_count_; | 275 int resource_list_load_count_; |
272 int change_list_load_count_; | 276 int change_list_load_count_; |
273 int directory_load_count_; | 277 int directory_load_count_; |
274 int about_resource_load_count_; | 278 int about_resource_load_count_; |
| 279 int app_list_load_count_; |
275 bool offline_; | 280 bool offline_; |
276 base::FilePath last_cancelled_file_; | 281 base::FilePath last_cancelled_file_; |
277 | 282 |
278 DISALLOW_COPY_AND_ASSIGN(FakeDriveService); | 283 DISALLOW_COPY_AND_ASSIGN(FakeDriveService); |
279 }; | 284 }; |
280 | 285 |
281 } // namespace drive | 286 } // namespace drive |
282 | 287 |
283 #endif // CHROME_BROWSER_DRIVE_FAKE_DRIVE_SERVICE_H_ | 288 #endif // CHROME_BROWSER_DRIVE_FAKE_DRIVE_SERVICE_H_ |
OLD | NEW |