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

Unified Diff: components/safe_json/safe_json_parser_impl.h

Issue 1951863002: Revert of Convert the utility process JSON parser into a Mojo service. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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
Index: components/safe_json/safe_json_parser_impl.h
diff --git a/components/safe_json/safe_json_parser_impl.h b/components/safe_json/safe_json_parser_impl.h
index eefa187d35b9d0f16800cfb2d6afe914d4711488..5f29bc03c52cd98a35a38485dcdb121d67f155d4 100644
--- a/components/safe_json/safe_json_parser_impl.h
+++ b/components/safe_json/safe_json_parser_impl.h
@@ -10,9 +10,6 @@
#include "base/macros.h"
#include "base/memory/ref_counted.h"
-#include "base/memory/weak_ptr.h"
-#include "base/threading/thread_checker.h"
-#include "components/safe_json/public/interfaces/safe_json.mojom.h"
#include "components/safe_json/safe_json_parser.h"
#include "content/public/browser/utility_process_host_client.h"
@@ -20,10 +17,6 @@
class ListValue;
class SequencedTaskRunner;
class Value;
-}
-
-namespace content {
-class UtilityProcessHost;
}
namespace IPC {
@@ -44,6 +37,9 @@
void StartWorkOnIOThread();
+ void OnJSONParseSucceeded(const base::ListValue& wrapper);
+ void OnJSONParseFailed(const std::string& error_message);
+
void ReportResults();
void ReportResultsOnOriginThread();
@@ -53,9 +49,6 @@
// SafeJsonParser implementation.
void Start() override;
- // mojom::SafeJsonParser::Parse callback.
- void OnParseDone(const base::ListValue& wrapper, mojo::String error);
-
const std::string unsafe_json_;
SuccessCallback success_callback_;
ErrorCallback error_callback_;
@@ -64,14 +57,6 @@
std::unique_ptr<base::Value> parsed_json_;
std::string error_;
- base::WeakPtr<content::UtilityProcessHost> utility_process_host_;
-
- mojom::SafeJsonParserPtr service_;
-
- // To ensure the UtilityProcessHost and Mojo service are only accessed on the
- // IO thread.
- base::ThreadChecker io_thread_checker_;
-
DISALLOW_COPY_AND_ASSIGN(SafeJsonParserImpl);
};
« no previous file with comments | « components/safe_json/public/interfaces/safe_json.typemap ('k') | components/safe_json/safe_json_parser_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698