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 #include "services/shell/public/cpp/service.h" | 5 #include "services/shell/public/cpp/service.h" |
6 | 6 |
7 #include "services/shell/public/cpp/service_context.h" | 7 #include "services/shell/public/cpp/service_context.h" |
8 | 8 |
9 namespace shell { | 9 namespace shell { |
10 | 10 |
11 Service::Service() {} | 11 Service::Service() {} |
12 Service::~Service() {} | 12 Service::~Service() {} |
13 | 13 |
14 void Service::OnStart(const Identity& identity) {} | 14 void Service::OnStart(const Identity& identity) {} |
15 | 15 |
16 bool Service::OnConnect(Connection* connection) { | 16 bool Service::OnConnect(const Identity& remote_identity, |
| 17 InterfaceRegistry* registry) { |
17 return false; | 18 return false; |
18 } | 19 } |
19 | 20 |
20 bool Service::OnStop() { return true; } | 21 bool Service::OnStop() { return true; } |
21 | 22 |
22 InterfaceProvider* Service::GetInterfaceProviderForConnection() { | |
23 return nullptr; | |
24 } | |
25 | |
26 InterfaceRegistry* Service::GetInterfaceRegistryForConnection() { | |
27 return nullptr; | |
28 } | |
29 | |
30 Connector* Service::connector() { | 23 Connector* Service::connector() { |
31 return context_->connector(); | 24 return context_->connector(); |
32 } | 25 } |
33 | 26 |
34 ServiceContext* Service::context() { | 27 ServiceContext* Service::context() { |
35 return context_.get(); | 28 return context_.get(); |
36 } | 29 } |
37 | 30 |
38 void Service::set_context(std::unique_ptr<ServiceContext> context) { | 31 void Service::set_context(std::unique_ptr<ServiceContext> context) { |
39 context_ = std::move(context); | 32 context_ = std::move(context); |
40 } | 33 } |
41 | 34 |
42 } // namespace shell | 35 } // namespace shell |
OLD | NEW |