| OLD | NEW |
| (Empty) |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef COMPONENTS_SAFE_JSON_SAFE_JSON_PARSER_MOJO_IMPL_H_ | |
| 6 #define COMPONENTS_SAFE_JSON_SAFE_JSON_PARSER_MOJO_IMPL_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "base/macros.h" | |
| 11 #include "components/safe_json/public/interfaces/safe_json.mojom.h" | |
| 12 #include "mojo/public/cpp/bindings/strong_binding.h" | |
| 13 | |
| 14 namespace safe_json { | |
| 15 | |
| 16 class SafeJsonParserMojoImpl : public mojom::SafeJsonParser { | |
| 17 public: | |
| 18 static void Create(mojo::InterfaceRequest<mojom::SafeJsonParser> request); | |
| 19 | |
| 20 private: | |
| 21 explicit SafeJsonParserMojoImpl( | |
| 22 mojo::InterfaceRequest<mojom::SafeJsonParser> request); | |
| 23 ~SafeJsonParserMojoImpl() override; | |
| 24 | |
| 25 // mojom::SafeJsonParser implementation. | |
| 26 void Parse(const mojo::String& json, const ParseCallback& callback) override; | |
| 27 | |
| 28 mojo::StrongBinding<mojom::SafeJsonParser> binding_; | |
| 29 | |
| 30 DISALLOW_COPY_AND_ASSIGN(SafeJsonParserMojoImpl); | |
| 31 }; | |
| 32 | |
| 33 } // namespace safe_json | |
| 34 | |
| 35 #endif // COMPONENTS_SAFE_JSON_SAFE_JSON_PARSER_MOJO_IMPL_H_ | |
| OLD | NEW |