OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 #ifndef EXTENSIONS_UTILITY_UTILITY_HANDLER_H_ | 5 #ifndef EXTENSIONS_UTILITY_UTILITY_HANDLER_H_ |
6 #define EXTENSIONS_UTILITY_UTILITY_HANDLER_H_ | 6 #define EXTENSIONS_UTILITY_UTILITY_HANDLER_H_ |
7 | 7 |
8 #include <string> | |
9 | |
10 #include "base/macros.h" | |
11 | |
12 namespace IPC { | |
13 class Message; | |
14 } | |
15 | |
16 namespace service_manager { | 8 namespace service_manager { |
17 class InterfaceRegistry; | 9 class InterfaceRegistry; |
18 } | 10 } |
19 | 11 |
20 namespace extensions { | 12 namespace extensions { |
21 | 13 |
22 // A handler for extensions-related IPC from within utility processes. | 14 namespace utility_handler { |
23 class UtilityHandler { | |
24 public: | |
25 UtilityHandler(); | |
26 ~UtilityHandler(); | |
27 | 15 |
28 static void UtilityThreadStarted(); | 16 void UtilityThreadStarted(); |
29 | 17 |
30 static void ExposeInterfacesToBrowser( | 18 void ExposeInterfacesToBrowser(service_manager::InterfaceRegistry* registry, |
31 service_manager::InterfaceRegistry* registry, | 19 bool running_elevated); |
32 bool running_elevated); | |
33 | 20 |
34 bool OnMessageReceived(const IPC::Message& message); | 21 } // namespace utility_handler |
35 | |
36 private: | |
37 // IPC message handlers. | |
38 void OnParseUpdateManifest(const std::string& xml); | |
39 | |
40 DISALLOW_COPY_AND_ASSIGN(UtilityHandler); | |
41 }; | |
42 | 22 |
43 } // namespace extensions | 23 } // namespace extensions |
44 | 24 |
45 #endif // EXTENSIONS_UTILITY_UTILITY_HANDLER_H_ | 25 #endif // EXTENSIONS_UTILITY_UTILITY_HANDLER_H_ |
OLD | NEW |