OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2014 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 MOJO_EXAMPLES_TEST_EXAMPLE_SERVICE_APPLICATION_H_ | |
6 #define MOJO_EXAMPLES_TEST_EXAMPLE_SERVICE_APPLICATION_H_ | |
7 | |
8 #include "mojo/public/cpp/application/application_delegate.h" | |
9 #include "mojo/public/cpp/application/interface_factory.h" | |
10 #include "mojo/public/cpp/system/macros.h" | |
11 | |
12 namespace mojo { | |
13 | |
14 class ApplicationConnection; | |
15 class ExampleService; | |
16 | |
17 class ExampleServiceApplication : public ApplicationDelegate, | |
18 public InterfaceFactory<ExampleService> { | |
19 public: | |
20 ExampleServiceApplication(); | |
21 virtual ~ExampleServiceApplication(); | |
22 | |
23 // ApplicationDelegate implementation. | |
Ben Goodger (Google)
2014/08/07 15:53:09
I have a habit of pushing interface implementation
msw
2014/08/07 18:31:16
Done.
| |
24 virtual bool ConfigureIncomingConnection(ApplicationConnection* connection) | |
25 MOJO_OVERRIDE; | |
26 | |
27 // InterfaceFactory<ExampleService> implementation. | |
28 virtual void Create(ApplicationConnection* connection, | |
Ben Goodger (Google)
2014/08/07 15:53:09
You could just add an InterfaceFactoryImpl member
msw
2014/08/07 18:31:16
Done.
| |
29 InterfaceRequest<ExampleService> request) MOJO_OVERRIDE; | |
30 | |
31 private: | |
32 MOJO_DISALLOW_COPY_AND_ASSIGN(ExampleServiceApplication); | |
33 }; | |
34 | |
35 } // namespace mojo | |
36 | |
37 #endif // MOJO_EXAMPLES_TEST_EXAMPLE_SERVICE_APPLICATION_H_ | |
OLD | NEW |