Chromium Code Reviews| Index: chrome/browser/google_apis/drive_api_operations.h |
| diff --git a/chrome/browser/google_apis/drive_api_operations.h b/chrome/browser/google_apis/drive_api_operations.h |
| index 527fca659dab950c22975579519a3cac15f9c8d7..8b92c881b4df35c4332e13f772368568fecb1f7d 100644 |
| --- a/chrome/browser/google_apis/drive_api_operations.h |
| +++ b/chrome/browser/google_apis/drive_api_operations.h |
| @@ -7,6 +7,7 @@ |
| #include <string> |
| +#include "base/callback.h" |
|
hashimoto
2013/03/01 02:29:19
nit: Can't this be replaced with callback_forward.
hidehiko
2013/03/01 03:53:55
Done.
|
| #include "chrome/browser/google_apis/base_operations.h" |
| #include "chrome/browser/google_apis/drive_api_url_generator.h" |
| #include "chrome/browser/google_apis/drive_service_interface.h" |
| @@ -17,6 +18,15 @@ class URLRequestContextGetter; |
| namespace google_apis { |
| +class FileResource; |
| + |
| +// Callback used for operations that the server returns FileResource data |
| +// formatted into JSON value. |
| +typedef base::Callback<void(GDataErrorCode error, |
| + scoped_ptr<FileResource> entry)> |
| + FileResourceCallback; |
| + |
| + |
| //============================== GetAboutOperation ============================= |
| // This class performs the operation for fetching About data. |
| @@ -125,7 +135,7 @@ class GetFileOperation : public GetDataOperation { |
| net::URLRequestContextGetter* url_request_context_getter, |
| const DriveApiUrlGenerator& url_generator, |
| const std::string& file_id, |
| - const GetDataCallback& callback); |
| + const FileResourceCallback& callback); |
| virtual ~GetFileOperation(); |
| protected: |
| @@ -157,7 +167,7 @@ class CreateDirectoryOperation : public GetDataOperation { |
| const DriveApiUrlGenerator& url_generator, |
| const std::string& parent_resource_id, |
| const std::string& directory_name, |
| - const GetDataCallback& callback); |
| + const FileResourceCallback& callback); |
| virtual ~CreateDirectoryOperation(); |
| protected: |