- add sources.
[platform/framework/web/crosswalk.git] / src / chrome / browser / drive / dummy_drive_service.h
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
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_DRIVE_DUMMY_DRIVE_SERVICE_H_
6 #define CHROME_BROWSER_DRIVE_DUMMY_DRIVE_SERVICE_H_
7
8 #include "chrome/browser/drive/drive_service_interface.h"
9 #include "chrome/browser/google_apis/auth_service_interface.h"
10
11 namespace drive {
12
13 // Dummy implementation of DriveServiceInterface.
14 // All functions do nothing, or return place holder values like 'true'.
15 class DummyDriveService : public DriveServiceInterface {
16  public:
17   DummyDriveService();
18   virtual ~DummyDriveService();
19
20   // DriveServiceInterface Overrides
21   virtual void Initialize(const std::string& account_id) OVERRIDE;
22   virtual void AddObserver(DriveServiceObserver* observer) OVERRIDE;
23   virtual void RemoveObserver(DriveServiceObserver* observer) OVERRIDE;
24   virtual bool CanSendRequest() const OVERRIDE;
25   virtual ResourceIdCanonicalizer GetResourceIdCanonicalizer() const OVERRIDE;
26   virtual bool HasAccessToken() const OVERRIDE;
27   virtual void RequestAccessToken(
28       const google_apis::AuthStatusCallback& callback) OVERRIDE;
29   virtual bool HasRefreshToken() const OVERRIDE;
30   virtual void ClearAccessToken() OVERRIDE;
31   virtual void ClearRefreshToken() OVERRIDE;
32   virtual std::string GetRootResourceId() const OVERRIDE;
33   virtual google_apis::CancelCallback GetAllResourceList(
34       const google_apis::GetResourceListCallback& callback) OVERRIDE;
35   virtual google_apis::CancelCallback GetResourceListInDirectory(
36       const std::string& directory_resource_id,
37       const google_apis::GetResourceListCallback& callback) OVERRIDE;
38   virtual google_apis::CancelCallback Search(
39       const std::string& search_query,
40       const google_apis::GetResourceListCallback& callback) OVERRIDE;
41   virtual google_apis::CancelCallback SearchByTitle(
42       const std::string& title,
43       const std::string& directory_resource_id,
44       const google_apis::GetResourceListCallback& callback) OVERRIDE;
45   virtual google_apis::CancelCallback GetChangeList(
46       int64 start_changestamp,
47       const google_apis::GetResourceListCallback& callback) OVERRIDE;
48   virtual google_apis::CancelCallback GetRemainingChangeList(
49       const GURL& next_link,
50       const google_apis::GetResourceListCallback& callback) OVERRIDE;
51   virtual google_apis::CancelCallback GetRemainingFileList(
52       const GURL& next_link,
53       const google_apis::GetResourceListCallback& callback) OVERRIDE;
54   virtual google_apis::CancelCallback GetResourceEntry(
55       const std::string& resource_id,
56       const google_apis::GetResourceEntryCallback& callback) OVERRIDE;
57   virtual google_apis::CancelCallback GetShareUrl(
58       const std::string& resource_id,
59       const GURL& embed_origin,
60       const google_apis::GetShareUrlCallback& callback) OVERRIDE;
61   virtual google_apis::CancelCallback GetAboutResource(
62       const google_apis::AboutResourceCallback& callback) OVERRIDE;
63   virtual google_apis::CancelCallback GetAppList(
64       const google_apis::AppListCallback& callback) OVERRIDE;
65   virtual google_apis::CancelCallback DeleteResource(
66       const std::string& resource_id,
67       const std::string& etag,
68       const google_apis::EntryActionCallback& callback) OVERRIDE;
69   virtual google_apis::CancelCallback DownloadFile(
70       const base::FilePath& local_cache_path,
71       const std::string& resource_id,
72       const google_apis::DownloadActionCallback& download_action_callback,
73       const google_apis::GetContentCallback& get_content_callback,
74       const google_apis::ProgressCallback& progress_callback) OVERRIDE;
75   virtual google_apis::CancelCallback CopyResource(
76       const std::string& resource_id,
77       const std::string& parent_resource_id,
78       const std::string& new_title,
79       const base::Time& last_modified,
80       const google_apis::GetResourceEntryCallback& callback) OVERRIDE;
81   virtual google_apis::CancelCallback CopyHostedDocument(
82       const std::string& resource_id,
83       const std::string& new_title,
84       const google_apis::GetResourceEntryCallback& callback) OVERRIDE;
85   virtual google_apis::CancelCallback MoveResource(
86       const std::string& resource_id,
87       const std::string& parent_resource_id,
88       const std::string& new_title,
89       const base::Time& last_modified,
90       const google_apis::GetResourceEntryCallback& callback) OVERRIDE;
91   virtual google_apis::CancelCallback RenameResource(
92       const std::string& resource_id,
93       const std::string& new_title,
94       const google_apis::EntryActionCallback& callback) OVERRIDE;
95   virtual google_apis::CancelCallback TouchResource(
96       const std::string& resource_id,
97       const base::Time& modified_date,
98       const base::Time& last_viewed_by_me_date,
99       const google_apis::GetResourceEntryCallback& callback) OVERRIDE;
100   virtual google_apis::CancelCallback AddResourceToDirectory(
101       const std::string& parent_resource_id,
102       const std::string& resource_id,
103       const google_apis::EntryActionCallback& callback) OVERRIDE;
104   virtual google_apis::CancelCallback RemoveResourceFromDirectory(
105       const std::string& parent_resource_id,
106       const std::string& resource_id,
107       const google_apis::EntryActionCallback& callback) OVERRIDE;
108   virtual google_apis::CancelCallback AddNewDirectory(
109       const std::string& parent_resource_id,
110       const std::string& directory_title,
111       const google_apis::GetResourceEntryCallback& callback) OVERRIDE;
112   virtual google_apis::CancelCallback InitiateUploadNewFile(
113       const std::string& content_type,
114       int64 content_length,
115       const std::string& parent_resource_id,
116       const std::string& title,
117       const google_apis::InitiateUploadCallback& callback) OVERRIDE;
118   virtual google_apis::CancelCallback InitiateUploadExistingFile(
119       const std::string& content_type,
120       int64 content_length,
121       const std::string& resource_id,
122       const std::string& etag,
123       const google_apis::InitiateUploadCallback& callback) OVERRIDE;
124   virtual google_apis::CancelCallback ResumeUpload(
125       const GURL& upload_url,
126       int64 start_position,
127       int64 end_position,
128       int64 content_length,
129       const std::string& content_type,
130       const base::FilePath& local_file_path,
131       const google_apis::UploadRangeCallback& callback,
132       const google_apis::ProgressCallback& progress_callback) OVERRIDE;
133   virtual google_apis::CancelCallback GetUploadStatus(
134       const GURL& upload_url,
135       int64 content_length,
136       const google_apis::UploadRangeCallback& callback) OVERRIDE;
137   virtual google_apis::CancelCallback AuthorizeApp(
138       const std::string& resource_id,
139       const std::string& app_id,
140       const google_apis::AuthorizeAppCallback& callback) OVERRIDE;
141   virtual google_apis::CancelCallback GetResourceListInDirectoryByWapi(
142       const std::string& directory_resource_id,
143       const google_apis::GetResourceListCallback& callback) OVERRIDE;
144   virtual google_apis::CancelCallback GetRemainingResourceList(
145       const GURL& next_link,
146       const google_apis::GetResourceListCallback& callback) OVERRIDE;
147 };
148
149 }  // namespace drive
150
151 #endif  // CHROME_BROWSER_DRIVE_DUMMY_DRIVE_SERVICE_H_