Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(29)

Side by Side Diff: chrome/browser/chromeos/gdata/gdata_documents_service.h

Issue 10821065: Add Drive API specific operations. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_CHROMEOS_GDATA_GDATA_DOCUMENTS_SERVICE_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_GDATA_DOCUMENTS_SERVICE_H_
6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_DOCUMENTS_SERVICE_H_ 6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_DOCUMENTS_SERVICE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 // |resource_id|. 96 // |resource_id|.
97 // Upon completion, invokes |callback| with results on the calling thread. 97 // Upon completion, invokes |callback| with results on the calling thread.
98 virtual void GetDocumentEntry(const std::string& resource_id, 98 virtual void GetDocumentEntry(const std::string& resource_id,
99 const GetDataCallback& callback) = 0; 99 const GetDataCallback& callback) = 0;
100 100
101 // Gets the account metadata from the server using the default account 101 // Gets the account metadata from the server using the default account
102 // metadata URL. Upon completion, invokes |callback| with results on the 102 // metadata URL. Upon completion, invokes |callback| with results on the
103 // calling thread. 103 // calling thread.
104 virtual void GetAccountMetadata(const GetDataCallback& callback) = 0; 104 virtual void GetAccountMetadata(const GetDataCallback& callback) = 0;
105 105
106 // Gets the About resource from the server for the current account.
107 // Upon completion, invokes |callback| with results on the calling thread.
108 // (For Drive V2 API only)
109 virtual void GetAboutResource(const GetDataCallback& callback) = 0;
110
111 // Gets the application list (For Drive V2 API only).
112 virtual void GetApplicationList(const GetDataCallback& callback) = 0;
113
106 // Deletes a document identified by its 'self' |url| and |etag|. 114 // Deletes a document identified by its 'self' |url| and |etag|.
107 // Upon completion, invokes |callback| with results on the calling thread. 115 // Upon completion, invokes |callback| with results on the calling thread.
108 virtual void DeleteDocument(const GURL& document_url, 116 virtual void DeleteDocument(const GURL& document_url,
109 const EntryActionCallback& callback) = 0; 117 const EntryActionCallback& callback) = 0;
110 118
111 // Downloads a document identified by its |content_url| in a given |format|. 119 // Downloads a document identified by its |content_url| in a given |format|.
112 // Upon completion, invokes |callback| with results on the calling thread. 120 // Upon completion, invokes |callback| with results on the calling thread.
113 virtual void DownloadDocument(const FilePath& virtual_path, 121 virtual void DownloadDocument(const FilePath& virtual_path,
114 const FilePath& local_cache_path, 122 const FilePath& local_cache_path,
115 const GURL& content_url, 123 const GURL& content_url,
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 virtual void Authenticate(const AuthStatusCallback& callback) OVERRIDE; 216 virtual void Authenticate(const AuthStatusCallback& callback) OVERRIDE;
209 virtual void GetDocuments(const GURL& feed_url, 217 virtual void GetDocuments(const GURL& feed_url,
210 int start_changestamp, 218 int start_changestamp,
211 const std::string& search_query, 219 const std::string& search_query,
212 const std::string& directory_resource_id, 220 const std::string& directory_resource_id,
213 const GetDataCallback& callback) OVERRIDE; 221 const GetDataCallback& callback) OVERRIDE;
214 virtual void GetDocumentEntry(const std::string& resource_id, 222 virtual void GetDocumentEntry(const std::string& resource_id,
215 const GetDataCallback& callback) OVERRIDE; 223 const GetDataCallback& callback) OVERRIDE;
216 224
217 virtual void GetAccountMetadata(const GetDataCallback& callback) OVERRIDE; 225 virtual void GetAccountMetadata(const GetDataCallback& callback) OVERRIDE;
226 virtual void GetAboutResource(const GetDataCallback& callback) OVERRIDE;
227 virtual void GetApplicationList(const GetDataCallback& callback) OVERRIDE;
218 virtual void DeleteDocument(const GURL& document_url, 228 virtual void DeleteDocument(const GURL& document_url,
219 const EntryActionCallback& callback) OVERRIDE; 229 const EntryActionCallback& callback) OVERRIDE;
220 virtual void DownloadDocument( 230 virtual void DownloadDocument(
221 const FilePath& virtual_path, 231 const FilePath& virtual_path,
222 const FilePath& local_cache_path, 232 const FilePath& local_cache_path,
223 const GURL& content_url, 233 const GURL& content_url,
224 DocumentExportFormat format, 234 DocumentExportFormat format,
225 const DownloadActionCallback& callback) OVERRIDE; 235 const DownloadActionCallback& callback) OVERRIDE;
226 virtual void DownloadFile( 236 virtual void DownloadFile(
227 const FilePath& virtual_path, 237 const FilePath& virtual_path,
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 Profile* profile_; 271 Profile* profile_;
262 272
263 scoped_ptr<GDataOperationRunner> runner_; 273 scoped_ptr<GDataOperationRunner> runner_;
264 274
265 DISALLOW_COPY_AND_ASSIGN(DocumentsService); 275 DISALLOW_COPY_AND_ASSIGN(DocumentsService);
266 }; 276 };
267 277
268 } // namespace gdata 278 } // namespace gdata
269 279
270 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_DOCUMENTS_SERVICE_H_ 280 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_DOCUMENTS_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698