| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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_FAKE_FILE_SYSTEM_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_FAKE_FILE_SYSTEM_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_FAKE_FILE_SYSTEM_H_ | 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_FAKE_FILE_SYSTEM_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/callback_forward.h" | 11 #include "base/callback_forward.h" |
| 12 #include "base/files/scoped_temp_dir.h" | 12 #include "base/files/scoped_temp_dir.h" |
| 13 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
| 14 #include "chrome/browser/chromeos/drive/file_errors.h" | 14 #include "chrome/browser/chromeos/drive/file_errors.h" |
| 15 #include "chrome/browser/chromeos/drive/file_system_interface.h" | 15 #include "chrome/browser/chromeos/drive/file_system_interface.h" |
| 16 #include "google_apis/drive/gdata_errorcode.h" | 16 #include "google_apis/drive/gdata_errorcode.h" |
| 17 | 17 |
| 18 namespace google_apis { | 18 namespace google_apis { |
| 19 | 19 |
| 20 class AboutResource; | 20 class AboutResource; |
| 21 class ResourceEntry; | 21 class ResourceEntry; |
| 22 class ResourceList; | |
| 23 | 22 |
| 24 } // namespace google_apis | 23 } // namespace google_apis |
| 25 | 24 |
| 26 namespace drive { | 25 namespace drive { |
| 27 | 26 |
| 28 class DriveServiceInterface; | 27 class DriveServiceInterface; |
| 29 class FileSystemObserver; | 28 class FileSystemObserver; |
| 30 class ResourceEntry; | 29 class ResourceEntry; |
| 31 | 30 |
| 32 namespace test_util { | 31 namespace test_util { |
| (...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 // file cannot be taken with the suffixed name. | 165 // file cannot be taken with the suffixed name. |
| 167 void GetResourceEntryAfterGetAboutResource( | 166 void GetResourceEntryAfterGetAboutResource( |
| 168 const GetResourceEntryCallback& callback, | 167 const GetResourceEntryCallback& callback, |
| 169 google_apis::GDataErrorCode gdata_error, | 168 google_apis::GDataErrorCode gdata_error, |
| 170 scoped_ptr<google_apis::AboutResource> about_resource); | 169 scoped_ptr<google_apis::AboutResource> about_resource); |
| 171 void GetResourceEntryAfterGetParentEntryInfo( | 170 void GetResourceEntryAfterGetParentEntryInfo( |
| 172 const base::FilePath& base_name, | 171 const base::FilePath& base_name, |
| 173 const GetResourceEntryCallback& callback, | 172 const GetResourceEntryCallback& callback, |
| 174 FileError error, | 173 FileError error, |
| 175 scoped_ptr<ResourceEntry> parent_entry); | 174 scoped_ptr<ResourceEntry> parent_entry); |
| 176 void GetResourceEntryAfterGetResourceList( | 175 void GetResourceEntryAfterGetFileList( |
| 177 const base::FilePath& base_name, | 176 const base::FilePath& base_name, |
| 178 const GetResourceEntryCallback& callback, | 177 const GetResourceEntryCallback& callback, |
| 179 google_apis::GDataErrorCode gdata_error, | 178 google_apis::GDataErrorCode gdata_error, |
| 180 scoped_ptr<google_apis::ResourceList> resource_list); | 179 scoped_ptr<google_apis::FileList> file_list); |
| 181 | 180 |
| 182 DriveServiceInterface* drive_service_; // Not owned. | 181 DriveServiceInterface* drive_service_; // Not owned. |
| 183 base::ScopedTempDir cache_dir_; | 182 base::ScopedTempDir cache_dir_; |
| 184 | 183 |
| 185 // Note: This should remain the last member so it'll be destroyed and | 184 // Note: This should remain the last member so it'll be destroyed and |
| 186 // invalidate the weak pointers before any other members are destroyed. | 185 // invalidate the weak pointers before any other members are destroyed. |
| 187 base::WeakPtrFactory<FakeFileSystem> weak_ptr_factory_; | 186 base::WeakPtrFactory<FakeFileSystem> weak_ptr_factory_; |
| 188 | 187 |
| 189 DISALLOW_COPY_AND_ASSIGN(FakeFileSystem); | 188 DISALLOW_COPY_AND_ASSIGN(FakeFileSystem); |
| 190 }; | 189 }; |
| 191 | 190 |
| 192 } // namespace test_util | 191 } // namespace test_util |
| 193 } // namespace drive | 192 } // namespace drive |
| 194 | 193 |
| 195 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_FAKE_FILE_SYSTEM_H_ | 194 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_FAKE_FILE_SYSTEM_H_ |
| OLD | NEW |