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

Unified Diff: google_apis/drive/base_requests.h

Issue 442193002: Parse Drive API responses all at once in the blocking pool. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | google_apis/drive/base_requests.cc » ('j') | google_apis/drive/drive_api_requests.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: google_apis/drive/base_requests.h
diff --git a/google_apis/drive/base_requests.h b/google_apis/drive/base_requests.h
index afe12a04fbef7ee5dac09b43bb35c136d16f8323..d9fbfaeb1583cad993888ac91803c2e28012a11e 100644
--- a/google_apis/drive/base_requests.h
+++ b/google_apis/drive/base_requests.h
@@ -29,10 +29,6 @@ namespace google_apis {
class RequestSender;
-// Callback used to pass parsed JSON from ParseJson(). If parsing error occurs,
-// then the passed argument is null.
-typedef base::Callback<void(scoped_ptr<base::Value> value)> ParseJsonCallback;
-
// Callback used for DownloadFileRequest and ResumeUploadRequestBase.
typedef base::Callback<void(int64 progress, int64 total)> ProgressCallback;
@@ -41,12 +37,8 @@ typedef base::Callback<void(
GDataErrorCode error,
scoped_ptr<std::string> content)> GetContentCallback;
-// Parses JSON passed in |json| on |blocking_task_runner|. Runs |callback| on
-// the calling thread when finished with either success or failure.
-// The callback must not be null.
-void ParseJson(base::TaskRunner* blocking_task_runner,
- const std::string& json,
- const ParseJsonCallback& callback);
+// Parses JSON passed in |json|. Returns NULL on failure.
+scoped_ptr<base::Value> ParseJson(const std::string& json);
//======================= AuthenticatedRequestInterface ======================
« no previous file with comments | « no previous file | google_apis/drive/base_requests.cc » ('j') | google_apis/drive/drive_api_requests.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698