Index: components/safe_json/utility/safe_json_parser_mojo_impl.h |
diff --git a/components/safe_json/utility/safe_json_parser_mojo_impl.h b/components/safe_json/utility/safe_json_parser_mojo_impl.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..cb407b7d304b3ca11eeb7587b9ee9381aac13bf9 |
--- /dev/null |
+++ b/components/safe_json/utility/safe_json_parser_mojo_impl.h |
@@ -0,0 +1,35 @@ |
+// Copyright 2013 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef COMPONENTS_SAFE_JSON_SAFE_JSON_PARSER_MOJO_IMPL_H_ |
+#define COMPONENTS_SAFE_JSON_SAFE_JSON_PARSER_MOJO_IMPL_H_ |
+ |
+#include <string> |
+ |
+#include "base/macros.h" |
+#include "components/safe_json/public/interfaces/safe_json.mojom.h" |
+#include "mojo/public/cpp/bindings/strong_binding.h" |
+ |
+namespace safe_json { |
+ |
+class SafeJsonParserMojoImpl : public mojom::SafeJsonParser { |
+ public: |
+ static void Create(mojo::InterfaceRequest<mojom::SafeJsonParser> request); |
+ |
+ private: |
+ explicit SafeJsonParserMojoImpl( |
+ mojo::InterfaceRequest<mojom::SafeJsonParser> request); |
+ ~SafeJsonParserMojoImpl() override; |
+ |
+ // mojom::SafeJsonParser implementation. |
+ void Parse(const mojo::String& json, const ParseCallback& callback) override; |
+ |
+ mojo::StrongBinding<mojom::SafeJsonParser> binding_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(SafeJsonParserMojoImpl); |
+}; |
+ |
+} // namespace safe_json |
+ |
+#endif // COMPONENTS_SAFE_JSON_SAFE_JSON_PARSER_MOJO_IMPL_H_ |