Chromium Code Reviews| Index: mojo/application/public/cpp/lib/service_registry.h |
| diff --git a/mojo/application/public/cpp/lib/service_registry.h b/mojo/application/public/cpp/lib/service_registry.h |
| index dcca5a04c70bba2dc520deb274fa4babfd8b4eb3..45ab30f22b8b0033602c5640ebe247babecece20 100644 |
| --- a/mojo/application/public/cpp/lib/service_registry.h |
| +++ b/mojo/application/public/cpp/lib/service_registry.h |
| @@ -5,6 +5,7 @@ |
| #ifndef MOJO_APPLICATION_PUBLIC_CPP_LIB_SERVICE_REGISTRY_H_ |
| #define MOJO_APPLICATION_PUBLIC_CPP_LIB_SERVICE_REGISTRY_H_ |
| +#include <set> |
| #include <string> |
| #include "mojo/application/public/cpp/application_connection.h" |
| @@ -24,11 +25,15 @@ namespace internal { |
| class ServiceRegistry : public ServiceProvider, public ApplicationConnection { |
| public: |
| ServiceRegistry(); |
| + // |allowed_interfaces| are the set of interfaces that the shell has allowed |
| + // an application to expose to another application. If this set is empty, the |
| + // application is allowed to expose all of its interfaces. |
| ServiceRegistry(ApplicationImpl* application_impl, |
| const std::string& connection_url, |
| const std::string& remote_url, |
| ServiceProviderPtr remote_services, |
| - InterfaceRequest<ServiceProvider> local_services); |
| + InterfaceRequest<ServiceProvider> local_services, |
| + std::set<std::string> allowed_interfaces); |
|
sky
2015/07/22 15:57:45
const std::set<std::string>&
|
| // ApplicationConnection overrides. |
| void SetServiceConnector(ServiceConnector* service_connector) override; |
| @@ -57,6 +62,7 @@ class ServiceRegistry : public ServiceProvider, public ApplicationConnection { |
| Binding<ServiceProvider> local_binding_; |
| ServiceProviderPtr remote_service_provider_; |
| ServiceConnectorRegistry service_connector_registry_; |
| + std::set<std::string> allowed_interfaces_; |
|
sky
2015/07/22 15:57:45
nit: const
|
| MOJO_DISALLOW_COPY_AND_ASSIGN(ServiceRegistry); |
| }; |