Commit da0622b2 authored by Julie Jeongeun Kim's avatar Julie Jeongeun Kim Committed by Commit Bot

Convert connector.mojom of chromecast to new Mojo types

This CL converts ExternalService and ExternalConnector
to new Mojo types.

It also updates RegisterServiceInstance and Clone from
connector.mojom and members and methods which implement
them.

Bug: 955171
Change-Id: I8b9c6ab70a65b8c5661b294ec0ccde742123522a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1803940
Commit-Queue: Julie Kim <jkim@igalia.com>
Reviewed-by: default avatarKenneth MacKay <kmackay@chromium.org>
Reviewed-by: default avatarOksana Zhuravlova <oksamyt@chromium.org>
Reviewed-by: default avatarSam McNally <sammc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#697446}
parent 8dab8bcb
...@@ -40,14 +40,12 @@ ChromiumServiceWrapper::ChromiumServiceWrapper( ...@@ -40,14 +40,12 @@ ChromiumServiceWrapper::ChromiumServiceWrapper(
std::unique_ptr<service_manager::Service> chromium_service, std::unique_ptr<service_manager::Service> chromium_service,
const std::string& service_name) const std::string& service_name)
: service_ptr_(std::move(service_ptr)), : service_ptr_(std::move(service_ptr)),
chromium_service_(std::move(chromium_service)), chromium_service_(std::move(chromium_service)) {
service_binding_(this) {
DCHECK(connector); DCHECK(connector);
DCHECK(chromium_service_); DCHECK(chromium_service_);
external_mojo::mojom::ExternalServicePtr ptr; connector->RegisterService(service_name,
service_binding_.Bind(mojo::MakeRequest(&ptr)); service_receiver_.BindNewPipeAndPassRemote());
connector->RegisterService(service_name, std::move(ptr));
} }
ChromiumServiceWrapper::~ChromiumServiceWrapper() = default; ChromiumServiceWrapper::~ChromiumServiceWrapper() = default;
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
#include "base/macros.h" #include "base/macros.h"
#include "chromecast/external_mojo/public/mojom/connector.mojom.h" #include "chromecast/external_mojo/public/mojom/connector.mojom.h"
#include "mojo/public/cpp/bindings/binding.h" #include "mojo/public/cpp/bindings/receiver.h"
#include "mojo/public/cpp/system/message_pipe.h" #include "mojo/public/cpp/system/message_pipe.h"
#include "services/service_manager/public/cpp/identity.h" #include "services/service_manager/public/cpp/identity.h"
#include "services/service_manager/public/cpp/service.h" #include "services/service_manager/public/cpp/service.h"
...@@ -44,7 +44,7 @@ class ChromiumServiceWrapper : public external_mojo::mojom::ExternalService { ...@@ -44,7 +44,7 @@ class ChromiumServiceWrapper : public external_mojo::mojom::ExternalService {
const service_manager::mojom::ServicePtr service_ptr_; const service_manager::mojom::ServicePtr service_ptr_;
const std::unique_ptr<service_manager::Service> chromium_service_; const std::unique_ptr<service_manager::Service> chromium_service_;
mojo::Binding<external_mojo::mojom::ExternalService> service_binding_; mojo::Receiver<external_mojo::mojom::ExternalService> service_receiver_{this};
DISALLOW_COPY_AND_ASSIGN(ChromiumServiceWrapper); DISALLOW_COPY_AND_ASSIGN(ChromiumServiceWrapper);
}; };
......
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
#include "chromecast/external_mojo/public/mojom/connector.mojom.h" #include "chromecast/external_mojo/public/mojom/connector.mojom.h"
#include "mojo/public/cpp/bindings/interface_ptr.h" #include "mojo/public/cpp/bindings/interface_ptr.h"
#include "mojo/public/cpp/bindings/interface_request.h" #include "mojo/public/cpp/bindings/interface_request.h"
#include "mojo/public/cpp/bindings/pending_remote.h"
#include "mojo/public/cpp/system/message_pipe.h" #include "mojo/public/cpp/system/message_pipe.h"
namespace chromecast { namespace chromecast {
...@@ -47,7 +48,8 @@ class ExternalConnector { ...@@ -47,7 +48,8 @@ class ExternalConnector {
ExternalService* service) = 0; ExternalService* service) = 0;
virtual void RegisterService( virtual void RegisterService(
const std::string& service_name, const std::string& service_name,
external_mojo::mojom::ExternalServicePtr service_ptr) = 0; mojo::PendingRemote<external_mojo::mojom::ExternalService>
service_remote) = 0;
// Asks the Mojo broker to bind to a matching interface on the service with // Asks the Mojo broker to bind to a matching interface on the service with
// the given |service_name|. If the service does not yet exist, the binding // the given |service_name|. If the service does not yet exist, the binding
......
...@@ -50,21 +50,22 @@ void ExternalConnector::Connect( ...@@ -50,21 +50,22 @@ void ExternalConnector::Connect(
kConnectRetryDelay); kConnectRetryDelay);
return; return;
} }
external_mojo::mojom::ExternalConnectorPtr connector( mojo::Remote<external_mojo::mojom::ExternalConnector> connector(
external_mojo::mojom::ExternalConnectorPtrInfo(std::move(pipe), 0)); mojo::PendingRemote<external_mojo::mojom::ExternalConnector>(
std::move(pipe), 0));
std::move(callback).Run( std::move(callback).Run(
std::make_unique<ExternalConnectorImpl>(std::move(connector))); std::make_unique<ExternalConnectorImpl>(std::move(connector)));
} }
ExternalConnectorImpl::ExternalConnectorImpl( ExternalConnectorImpl::ExternalConnectorImpl(
external_mojo::mojom::ExternalConnectorPtr connector) mojo::Remote<external_mojo::mojom::ExternalConnector> connector)
: connector_(std::move(connector)) { : connector_(std::move(connector)) {
connector_.set_connection_error_handler(base::BindOnce( connector_.set_disconnect_handler(base::BindOnce(
&ExternalConnectorImpl::OnConnectionError, base::Unretained(this))); &ExternalConnectorImpl::OnMojoDisconnect, base::Unretained(this)));
} }
ExternalConnectorImpl::ExternalConnectorImpl( ExternalConnectorImpl::ExternalConnectorImpl(
external_mojo::mojom::ExternalConnectorPtrInfo unbound_state) mojo::PendingRemote<external_mojo::mojom::ExternalConnector> unbound_state)
: unbound_state_(std::move(unbound_state)) { : unbound_state_(std::move(unbound_state)) {
DETACH_FROM_SEQUENCE(sequence_checker_); DETACH_FROM_SEQUENCE(sequence_checker_);
} }
...@@ -78,14 +79,15 @@ void ExternalConnectorImpl::SetConnectionErrorCallback( ...@@ -78,14 +79,15 @@ void ExternalConnectorImpl::SetConnectionErrorCallback(
void ExternalConnectorImpl::RegisterService(const std::string& service_name, void ExternalConnectorImpl::RegisterService(const std::string& service_name,
ExternalService* service) { ExternalService* service) {
RegisterService(service_name, service->GetBinding()); RegisterService(service_name, service->GetReceiver());
} }
void ExternalConnectorImpl::RegisterService( void ExternalConnectorImpl::RegisterService(
const std::string& service_name, const std::string& service_name,
external_mojo::mojom::ExternalServicePtr service_ptr) { mojo::PendingRemote<external_mojo::mojom::ExternalService> service_remote) {
if (BindConnectorIfNecessary()) { if (BindConnectorIfNecessary()) {
connector_->RegisterServiceInstance(service_name, std::move(service_ptr)); connector_->RegisterServiceInstance(service_name,
std::move(service_remote));
} }
} }
...@@ -109,12 +111,12 @@ void ExternalConnectorImpl::BindInterface( ...@@ -109,12 +111,12 @@ void ExternalConnectorImpl::BindInterface(
} }
std::unique_ptr<ExternalConnector> ExternalConnectorImpl::Clone() { std::unique_ptr<ExternalConnector> ExternalConnectorImpl::Clone() {
external_mojo::mojom::ExternalConnectorPtrInfo connector_info; mojo::PendingRemote<external_mojo::mojom::ExternalConnector> connector_remote;
auto request = mojo::MakeRequest(&connector_info); auto receiver = connector_remote.InitWithNewPipeAndPassReceiver();
if (BindConnectorIfNecessary()) { if (BindConnectorIfNecessary()) {
connector_->Clone(std::move(request)); connector_->Clone(std::move(receiver));
} }
return std::make_unique<ExternalConnectorImpl>(std::move(connector_info)); return std::make_unique<ExternalConnectorImpl>(std::move(connector_remote));
} }
void ExternalConnectorImpl::SendChromiumConnectorRequest( void ExternalConnectorImpl::SendChromiumConnectorRequest(
...@@ -124,7 +126,7 @@ void ExternalConnectorImpl::SendChromiumConnectorRequest( ...@@ -124,7 +126,7 @@ void ExternalConnectorImpl::SendChromiumConnectorRequest(
} }
} }
void ExternalConnectorImpl::OnConnectionError() { void ExternalConnectorImpl::OnMojoDisconnect() {
DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
connector_.reset(); connector_.reset();
if (connection_error_callback_) { if (connection_error_callback_) {
...@@ -141,13 +143,13 @@ bool ExternalConnectorImpl::BindConnectorIfNecessary() { ...@@ -141,13 +143,13 @@ bool ExternalConnectorImpl::BindConnectorIfNecessary() {
} }
if (!unbound_state_.is_valid()) { if (!unbound_state_.is_valid()) {
// OnConnectionError was already called, but |this| was not destroyed. // OnMojoDisconnect was already called, but |this| was not destroyed.
return false; return false;
} }
connector_.Bind(std::move(unbound_state_)); connector_.Bind(std::move(unbound_state_));
connector_.set_connection_error_handler(base::BindOnce( connector_.set_disconnect_handler(base::BindOnce(
&ExternalConnectorImpl::OnConnectionError, base::Unretained(this))); &ExternalConnectorImpl::OnMojoDisconnect, base::Unretained(this)));
return true; return true;
} }
......
...@@ -13,6 +13,8 @@ ...@@ -13,6 +13,8 @@
#include "base/macros.h" #include "base/macros.h"
#include "base/sequence_checker.h" #include "base/sequence_checker.h"
#include "chromecast/external_mojo/external_service_support/external_connector.h" #include "chromecast/external_mojo/external_service_support/external_connector.h"
#include "mojo/public/cpp/bindings/pending_remote.h"
#include "mojo/public/cpp/bindings/remote.h"
namespace chromecast { namespace chromecast {
namespace external_service_support { namespace external_service_support {
...@@ -20,9 +22,10 @@ namespace external_service_support { ...@@ -20,9 +22,10 @@ namespace external_service_support {
class ExternalConnectorImpl : public ExternalConnector { class ExternalConnectorImpl : public ExternalConnector {
public: public:
explicit ExternalConnectorImpl( explicit ExternalConnectorImpl(
external_mojo::mojom::ExternalConnectorPtr connector); mojo::Remote<external_mojo::mojom::ExternalConnector> connector);
explicit ExternalConnectorImpl( explicit ExternalConnectorImpl(
external_mojo::mojom::ExternalConnectorPtrInfo unbound_state); mojo::PendingRemote<external_mojo::mojom::ExternalConnector>
unbound_state);
~ExternalConnectorImpl() override; ~ExternalConnectorImpl() override;
// ExternalConnector implementation: // ExternalConnector implementation:
...@@ -31,7 +34,8 @@ class ExternalConnectorImpl : public ExternalConnector { ...@@ -31,7 +34,8 @@ class ExternalConnectorImpl : public ExternalConnector {
ExternalService* service) override; ExternalService* service) override;
void RegisterService( void RegisterService(
const std::string& service_name, const std::string& service_name,
external_mojo::mojom::ExternalServicePtr service_ptr) override; mojo::PendingRemote<external_mojo::mojom::ExternalService> service_remote)
override;
void BindInterface(const std::string& service_name, void BindInterface(const std::string& service_name,
const std::string& interface_name, const std::string& interface_name,
mojo::ScopedMessagePipeHandle interface_pipe) override; mojo::ScopedMessagePipeHandle interface_pipe) override;
...@@ -45,11 +49,11 @@ class ExternalConnectorImpl : public ExternalConnector { ...@@ -45,11 +49,11 @@ class ExternalConnectorImpl : public ExternalConnector {
callback) override; callback) override;
private: private:
void OnConnectionError(); void OnMojoDisconnect();
bool BindConnectorIfNecessary(); bool BindConnectorIfNecessary();
external_mojo::mojom::ExternalConnectorPtr connector_; mojo::Remote<external_mojo::mojom::ExternalConnector> connector_;
external_mojo::mojom::ExternalConnectorPtrInfo unbound_state_; mojo::PendingRemote<external_mojo::mojom::ExternalConnector> unbound_state_;
base::OnceClosure connection_error_callback_; base::OnceClosure connection_error_callback_;
SEQUENCE_CHECKER(sequence_checker_); SEQUENCE_CHECKER(sequence_checker_);
......
...@@ -9,18 +9,17 @@ ...@@ -9,18 +9,17 @@
namespace chromecast { namespace chromecast {
namespace external_service_support { namespace external_service_support {
ExternalService::ExternalService() : service_binding_(this) {} ExternalService::ExternalService() = default;
ExternalService::~ExternalService() { ExternalService::~ExternalService() {
DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
} }
external_mojo::mojom::ExternalServicePtr ExternalService::GetBinding() { mojo::PendingRemote<external_mojo::mojom::ExternalService>
ExternalService::GetReceiver() {
DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
service_binding_.Close(); service_receiver_.reset();
external_mojo::mojom::ExternalServicePtr ptr; return service_receiver_.BindNewPipeAndPassRemote();
service_binding_.Bind(mojo::MakeRequest(&ptr));
return ptr;
} }
void ExternalService::AddInterface(const std::string& interface_name, void ExternalService::AddInterface(const std::string& interface_name,
......
...@@ -14,8 +14,8 @@ ...@@ -14,8 +14,8 @@
#include "base/macros.h" #include "base/macros.h"
#include "base/sequence_checker.h" #include "base/sequence_checker.h"
#include "chromecast/external_mojo/public/mojom/connector.mojom.h" #include "chromecast/external_mojo/public/mojom/connector.mojom.h"
#include "mojo/public/cpp/bindings/binding.h"
#include "mojo/public/cpp/bindings/interface_request.h" #include "mojo/public/cpp/bindings/interface_request.h"
#include "mojo/public/cpp/bindings/receiver.h"
#include "mojo/public/cpp/system/message_pipe.h" #include "mojo/public/cpp/system/message_pipe.h"
namespace chromecast { namespace chromecast {
...@@ -27,8 +27,8 @@ class ExternalService : public external_mojo::mojom::ExternalService { ...@@ -27,8 +27,8 @@ class ExternalService : public external_mojo::mojom::ExternalService {
ExternalService(); ExternalService();
~ExternalService() override; ~ExternalService() override;
// Returns the Mojo binding for this service. // Returns the Mojo receiver for this service.
external_mojo::mojom::ExternalServicePtr GetBinding(); mojo::PendingRemote<external_mojo::mojom::ExternalService> GetReceiver();
// Adds an interface that users of this service may bind to. To avoid races // Adds an interface that users of this service may bind to. To avoid races
// where the service is registered but interfaces cannot be bound by other // where the service is registered but interfaces cannot be bound by other
...@@ -94,7 +94,7 @@ class ExternalService : public external_mojo::mojom::ExternalService { ...@@ -94,7 +94,7 @@ class ExternalService : public external_mojo::mojom::ExternalService {
mojo::ScopedMessagePipeHandle interface_pipe) override; mojo::ScopedMessagePipeHandle interface_pipe) override;
std::map<std::string, std::unique_ptr<Binder>> binders_; std::map<std::string, std::unique_ptr<Binder>> binders_;
mojo::Binding<external_mojo::mojom::ExternalService> service_binding_; mojo::Receiver<external_mojo::mojom::ExternalService> service_receiver_{this};
SEQUENCE_CHECKER(sequence_checker_); SEQUENCE_CHECKER(sequence_checker_);
......
...@@ -20,6 +20,8 @@ ...@@ -20,6 +20,8 @@
#include "chromecast/external_mojo/public/mojom/connector.mojom.h" #include "chromecast/external_mojo/public/mojom/connector.mojom.h"
#include "mojo/public/cpp/bindings/binding_set.h" #include "mojo/public/cpp/bindings/binding_set.h"
#include "mojo/public/cpp/bindings/pending_receiver.h" #include "mojo/public/cpp/bindings/pending_receiver.h"
#include "mojo/public/cpp/bindings/receiver_set.h"
#include "mojo/public/cpp/bindings/remote.h"
#include "mojo/public/cpp/platform/named_platform_channel.h" #include "mojo/public/cpp/platform/named_platform_channel.h"
#include "mojo/public/cpp/platform/platform_channel_endpoint.h" #include "mojo/public/cpp/platform/platform_channel_endpoint.h"
#include "mojo/public/cpp/platform/platform_handle.h" #include "mojo/public/cpp/platform/platform_handle.h"
...@@ -73,8 +75,8 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector { ...@@ -73,8 +75,8 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector {
RegisterExternalServices(external_services_to_proxy); RegisterExternalServices(external_services_to_proxy);
} }
void AddBinding(mojom::ExternalConnectorRequest request) { void AddReceiver(mojo::PendingReceiver<mojom::ExternalConnector> receiver) {
bindings_.AddBinding(this, std::move(request)); receivers_.Add(this, std::move(receiver));
} }
private: private:
...@@ -217,14 +219,16 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector { ...@@ -217,14 +219,16 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector {
} }
// standalone::mojom::Connector implementation: // standalone::mojom::Connector implementation:
void RegisterServiceInstance(const std::string& service_name, void RegisterServiceInstance(
mojom::ExternalServicePtr service) override { const std::string& service_name,
mojo::PendingRemote<mojom::ExternalService> service_remote) override {
if (services_.find(service_name) != services_.end()) { if (services_.find(service_name) != services_.end()) {
LOG(ERROR) << "Duplicate service " << service_name; LOG(ERROR) << "Duplicate service " << service_name;
return; return;
} }
LOG(INFO) << "Register service " << service_name; LOG(INFO) << "Register service " << service_name;
service.set_connection_error_handler(base::BindOnce( mojo::Remote<mojom::ExternalService> service(std::move(service_remote));
service.set_disconnect_handler(base::BindOnce(
&ConnectorImpl::OnServiceLost, base::Unretained(this), service_name)); &ConnectorImpl::OnServiceLost, base::Unretained(this), service_name));
auto it = services_.emplace(service_name, std::move(service)).first; auto it = services_.emplace(service_name, std::move(service)).first;
...@@ -266,8 +270,9 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector { ...@@ -266,8 +270,9 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector {
std::move(interface_pipe))); std::move(interface_pipe)));
} }
void Clone(mojom::ExternalConnectorRequest request) override { void Clone(
AddBinding(std::move(request)); mojo::PendingReceiver<mojom::ExternalConnector> receiver) override {
AddReceiver(std::move(receiver));
} }
void BindChromiumConnector( void BindChromiumConnector(
...@@ -325,11 +330,11 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector { ...@@ -325,11 +330,11 @@ class ExternalMojoBroker::ConnectorImpl : public mojom::ExternalConnector {
ServiceManagerConnectorFacade connector_facade_; ServiceManagerConnectorFacade connector_facade_;
std::unique_ptr<service_manager::Connector> connector_; std::unique_ptr<service_manager::Connector> connector_;
mojo::BindingSet<mojom::ExternalConnector> bindings_; mojo::ReceiverSet<mojom::ExternalConnector> receivers_;
std::map<std::string, std::unique_ptr<ExternalServiceProxy>> std::map<std::string, std::unique_ptr<ExternalServiceProxy>>
registered_external_services_; registered_external_services_;
std::map<std::string, mojom::ExternalServicePtr> services_; std::map<std::string, mojo::Remote<mojom::ExternalService>> services_;
std::map<std::string, std::vector<PendingBindRequest>> pending_bind_requests_; std::map<std::string, std::vector<PendingBindRequest>> pending_bind_requests_;
std::map<std::string, mojom::ExternalServiceInfo> services_info_; std::map<std::string, mojom::ExternalServiceInfo> services_info_;
...@@ -361,7 +366,8 @@ class ExternalMojoBroker::ReadWatcher ...@@ -361,7 +366,8 @@ class ExternalMojoBroker::ReadWatcher
std::move(invitation), base::kNullProcessHandle, std::move(invitation), base::kNullProcessHandle,
mojo::PlatformChannelEndpoint( mojo::PlatformChannelEndpoint(
mojo::PlatformHandle(std::move(accepted_fd)))); mojo::PlatformHandle(std::move(accepted_fd))));
connector_->AddBinding(mojom::ExternalConnectorRequest(std::move(pipe))); connector_->AddReceiver(
mojo::PendingReceiver<mojom::ExternalConnector>(std::move(pipe)));
} }
} }
...@@ -398,10 +404,11 @@ void ExternalMojoBroker::InitializeChromium( ...@@ -398,10 +404,11 @@ void ExternalMojoBroker::InitializeChromium(
external_services_to_proxy); external_services_to_proxy);
} }
mojom::ExternalConnectorPtr ExternalMojoBroker::CreateConnector() { mojo::PendingRemote<mojom::ExternalConnector>
mojom::ExternalConnectorPtrInfo info; ExternalMojoBroker::CreateConnector() {
connector_->AddBinding(mojo::MakeRequest(&info)); mojo::PendingRemote<mojom::ExternalConnector> remote;
return mojom::ExternalConnectorPtr(std::move(info)); connector_->AddReceiver(remote.InitWithNewPipeAndPassReceiver());
return remote;
} }
ExternalMojoBroker::~ExternalMojoBroker() = default; ExternalMojoBroker::~ExternalMojoBroker() = default;
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
#include "base/macros.h" #include "base/macros.h"
#include "chromecast/external_mojo/public/mojom/connector.mojom.h" #include "chromecast/external_mojo/public/mojom/connector.mojom.h"
#include "mojo/public/cpp/bindings/pending_remote.h"
namespace service_manager { namespace service_manager {
class Connector; class Connector;
...@@ -35,7 +36,7 @@ class ExternalMojoBroker { ...@@ -35,7 +36,7 @@ class ExternalMojoBroker {
std::unique_ptr<service_manager::Connector> connector, std::unique_ptr<service_manager::Connector> connector,
const std::vector<std::string>& external_services_to_proxy); const std::vector<std::string>& external_services_to_proxy);
mojom::ExternalConnectorPtr CreateConnector(); mojo::PendingRemote<mojom::ExternalConnector> CreateConnector();
private: private:
class ConnectorImpl; class ConnectorImpl;
......
...@@ -33,7 +33,7 @@ interface ExternalService { ...@@ -33,7 +33,7 @@ interface ExternalService {
interface ExternalConnector { interface ExternalConnector {
// Registers a service with the broker. // Registers a service with the broker.
RegisterServiceInstance(string service_name, RegisterServiceInstance(string service_name,
ExternalService service); pending_remote<ExternalService> service);
// Asks the broker to pass the |interface_pipe| to the registered service with // Asks the broker to pass the |interface_pipe| to the registered service with
// the given |service_name| to be bound to the appropriate interface. If the // the given |service_name| to be bound to the appropriate interface. If the
...@@ -43,9 +43,9 @@ interface ExternalConnector { ...@@ -43,9 +43,9 @@ interface ExternalConnector {
string interface_name, string interface_name,
handle<message_pipe> interface_pipe); handle<message_pipe> interface_pipe);
// Creates a new binding to the Connector implementation, to allow clients to // Binds a new receiver to the Connector implementation, to allow clients to
// clone Connector pointers for use on other threads. // clone Connector pointers for use on other threads.
Clone(ExternalConnector& request); Clone(pending_receiver<ExternalConnector> receiver);
// Binds to a Chromium service_manager::Connector instance, if possible. // Binds to a Chromium service_manager::Connector instance, if possible.
BindChromiumConnector(handle<message_pipe> interface_pipe); BindChromiumConnector(handle<message_pipe> interface_pipe);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment