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_GOOGLE_APIS_DRIVE_SERVICE_INTERFACE_H_ | 5 #ifndef CHROME_BROWSER_GOOGLE_APIS_DRIVE_SERVICE_INTERFACE_H_ |
6 #define CHROME_BROWSER_GOOGLE_APIS_DRIVE_SERVICE_INTERFACE_H_ | 6 #define CHROME_BROWSER_GOOGLE_APIS_DRIVE_SERVICE_INTERFACE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 // TODO(kochi): Further split gdata_operations.h and include only necessary | 10 // TODO(kochi): Further split gdata_operations.h and include only necessary |
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
235 // Initiates uploading of a document/file. | 235 // Initiates uploading of a document/file. |
236 // |callback| must not be null. | 236 // |callback| must not be null. |
237 virtual void InitiateUpload(const InitiateUploadParams& params, | 237 virtual void InitiateUpload(const InitiateUploadParams& params, |
238 const InitiateUploadCallback& callback) = 0; | 238 const InitiateUploadCallback& callback) = 0; |
239 | 239 |
240 // Resumes uploading of a document/file on the calling thread. | 240 // Resumes uploading of a document/file on the calling thread. |
241 // |callback| must not be null. | 241 // |callback| must not be null. |
242 virtual void ResumeUpload(const ResumeUploadParams& params, | 242 virtual void ResumeUpload(const ResumeUploadParams& params, |
243 const ResumeUploadCallback& callback) = 0; | 243 const ResumeUploadCallback& callback) = 0; |
244 | 244 |
| 245 // Returns the current uploading state from the server. |
| 246 // |callback| must not be null. |
| 247 virtual void GetUploadState( |
| 248 const UploadMode upload_mode, |
| 249 const FilePath& drive_file_path, |
| 250 const GURL& upload_url, |
| 251 int64 content_length, |
| 252 const ResumeUploadCallback& callback) = 0; |
| 253 |
245 // Authorizes a Drive app with the id |app_id| to open the given file. | 254 // Authorizes a Drive app with the id |app_id| to open the given file. |
246 // Upon completion, invokes |callback| with the link to open the file with | 255 // Upon completion, invokes |callback| with the link to open the file with |
247 // the provided app. |callback| must not be null. | 256 // the provided app. |callback| must not be null. |
248 virtual void AuthorizeApp(const GURL& edit_url, | 257 virtual void AuthorizeApp(const GURL& edit_url, |
249 const std::string& app_id, | 258 const std::string& app_id, |
250 const AuthorizeAppCallback& callback) = 0; | 259 const AuthorizeAppCallback& callback) = 0; |
251 }; | 260 }; |
252 | 261 |
253 } // namespace google_apis | 262 } // namespace google_apis |
254 | 263 |
255 #endif // CHROME_BROWSER_GOOGLE_APIS_DRIVE_SERVICE_INTERFACE_H_ | 264 #endif // CHROME_BROWSER_GOOGLE_APIS_DRIVE_SERVICE_INTERFACE_H_ |
OLD | NEW |