| 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 module service_manager.mojom; | 5 module service_manager.mojom; |
| 6 | 6 |
| 7 import "services/service_manager/public/interfaces/connector.mojom"; | 7 import "services/service_manager/public/interfaces/connector.mojom"; |
| 8 import "services/service_manager/public/interfaces/interface_provider.mojom"; | 8 import "services/service_manager/public/interfaces/interface_provider.mojom"; |
| 9 import "services/service_manager/public/interfaces/interface_provider_spec.mojom
"; | 9 import "services/service_manager/public/interfaces/interface_provider_spec.mojom
"; |
| 10 import "services/service_manager/public/interfaces/service_control.mojom"; | |
| 11 | 10 |
| 12 // Metadata describing an instance of a service. | 11 // Metadata describing an instance of a service. |
| 13 struct ServiceInfo { | 12 struct ServiceInfo { |
| 14 // The service's identity. | 13 // The service's identity. |
| 15 Identity identity; | 14 Identity identity; |
| 16 | 15 |
| 17 // The service's interface provider specs, from its manifest. | 16 // The service's interface provider specs, from its manifest. |
| 18 map<string, InterfaceProviderSpec> interface_provider_specs; | 17 map<string, InterfaceProviderSpec> interface_provider_specs; |
| 19 }; | 18 }; |
| 20 | 19 |
| (...skipping 14 matching lines...) Expand all Loading... |
| 35 // * The user associated with this instance in the service manager. This | 34 // * The user associated with this instance in the service manager. This |
| 36 // will never be kInheritUserID. | 35 // will never be kInheritUserID. |
| 37 // * The instance group this instance belongs to. | 36 // * The instance group this instance belongs to. |
| 38 // | 37 // |
| 39 // Response parameters: | 38 // Response parameters: |
| 40 // | 39 // |
| 41 // connector_request | 40 // connector_request |
| 42 // An optional Connector request for the service manager to bind, allowing | 41 // An optional Connector request for the service manager to bind, allowing |
| 43 // the initialized client to connect to others. | 42 // the initialized client to connect to others. |
| 44 // | 43 // |
| 45 // control_request | 44 OnStart(ServiceInfo info) => (Connector&? connector_request); |
| 46 // An optional associated ServiceControl request. | |
| 47 // | |
| 48 OnStart(ServiceInfo info) => (Connector&? connector_request, | |
| 49 associated ServiceControl&? control_request); | |
| 50 | 45 |
| 51 // Called when another service attempts to open a connection to this | 46 // Called when another service attempts to open a connection to this |
| 52 // service. A service implements this method to complete the exchange | 47 // service. A service implements this method to complete the exchange |
| 53 // of interface implementations with the remote service. See also | 48 // of interface implementations with the remote service. See also |
| 54 // documentation in service_manager.mojom for Connect(). The service | 49 // documentation in service_manager.mojom for Connect(). The service |
| 55 // originating the request is referred to as the "source" and the one | 50 // originating the request is referred to as the "source" and the one |
| 56 // receiving the "target". | 51 // receiving the "target". |
| 57 // | 52 // |
| 58 // The Service must respond to acknowledge receipt of the request. | |
| 59 // | |
| 60 // Parameters: | 53 // Parameters: |
| 61 // | 54 // |
| 62 // source_info | 55 // source_info |
| 63 // Contains the source identity and interface provider specs. | 56 // Contains the source identity and interface provider specs. |
| 64 // | 57 // |
| 65 // interfaces | 58 // interfaces |
| 66 // A request for an InterfaceProvider by which the source service may | 59 // A request for an InterfaceProvider by which the source service may |
| 67 // seek to bind interface implementations exported by the target. | 60 // seek to bind interface implementations exported by the target. |
| 68 // | 61 // |
| 69 OnConnect(ServiceInfo source_info, InterfaceProvider&? interfaces) => (); | 62 OnConnect(ServiceInfo source_info, |
| 63 InterfaceProvider&? interfaces); |
| 70 }; | 64 }; |
| OLD | NEW |