OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include <memory> | 5 #include <memory> |
6 #include <string> | 6 #include <string> |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "examples/hello_mojo/hello_mojo.mojom.h" | 9 #include "examples/hello_mojo/hello_mojo.mojom.h" |
10 #include "mojo/public/c/system/main.h" | 10 #include "mojo/public/c/system/main.h" |
11 #include "mojo/public/cpp/application/application_connection.h" | |
12 #include "mojo/public/cpp/application/application_delegate.h" | 11 #include "mojo/public/cpp/application/application_delegate.h" |
13 #include "mojo/public/cpp/application/application_runner.h" | 12 #include "mojo/public/cpp/application/application_runner.h" |
| 13 #include "mojo/public/cpp/application/service_provider_impl.h" |
14 #include "mojo/public/cpp/bindings/interface_request.h" | 14 #include "mojo/public/cpp/bindings/interface_request.h" |
15 #include "mojo/public/cpp/bindings/strong_binding.h" | 15 #include "mojo/public/cpp/bindings/strong_binding.h" |
16 #include "mojo/public/cpp/system/macros.h" | 16 #include "mojo/public/cpp/system/macros.h" |
17 | 17 |
18 using examples::HelloMojo; | 18 using examples::HelloMojo; |
19 | 19 |
20 namespace { | 20 namespace { |
21 | 21 |
22 class HelloMojoImpl : public HelloMojo { | 22 class HelloMojoImpl : public HelloMojo { |
23 public: | 23 public: |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 MOJO_DISALLOW_COPY_AND_ASSIGN(HelloMojoServerApp); | 57 MOJO_DISALLOW_COPY_AND_ASSIGN(HelloMojoServerApp); |
58 }; | 58 }; |
59 | 59 |
60 } // namespace | 60 } // namespace |
61 | 61 |
62 MojoResult MojoMain(MojoHandle application_request) { | 62 MojoResult MojoMain(MojoHandle application_request) { |
63 return mojo::ApplicationRunner(std::unique_ptr<mojo::ApplicationDelegate>( | 63 return mojo::ApplicationRunner(std::unique_ptr<mojo::ApplicationDelegate>( |
64 new HelloMojoServerApp())) | 64 new HelloMojoServerApp())) |
65 .Run(application_request); | 65 .Run(application_request); |
66 } | 66 } |
OLD | NEW |