Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(511)

Unified Diff: services/service_manager/public/cpp/connector.h

Issue 2775483003: Use public Service Manager Connector API in Blink (Closed)
Patch Set: . Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/test/BUILD.gn ('k') | services/service_manager/public/cpp/lib/connector_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/service_manager/public/cpp/connector.h
diff --git a/services/service_manager/public/cpp/connector.h b/services/service_manager/public/cpp/connector.h
index 00e8d0a4beccd290851dfec1dfdf1b21d65583f6..37d833815445f21a456b900f3c087edaeeb462ac 100644
--- a/services/service_manager/public/cpp/connector.h
+++ b/services/service_manager/public/cpp/connector.h
@@ -38,11 +38,15 @@ class Connector {
public:
using Binder = base::Callback<void(mojo::ScopedMessagePipeHandle)>;
explicit TestApi(Connector* connector) : connector_(connector) {}
+
// Allows caller to specify a callback to bind requests for |interface_name|
- // locally, rather than passing the request through the Service Manager.
- void OverrideBinderForTesting(const std::string& interface_name,
+ // from |service_name| locally, rather than passing the request through the
+ // Service Manager.
+ void OverrideBinderForTesting(const std::string& service_name,
+ const std::string& interface_name,
const Binder& binder) {
- connector_->OverrideBinderForTesting(interface_name, binder);
+ connector_->OverrideBinderForTesting(service_name, interface_name,
+ binder);
}
void ClearBinderOverrides() { connector_->ClearBinderOverrides(); }
@@ -106,7 +110,8 @@ class Connector {
virtual base::WeakPtr<Connector> GetWeakPtr() = 0;
protected:
- virtual void OverrideBinderForTesting(const std::string& interface_name,
+ virtual void OverrideBinderForTesting(const std::string& service_name,
+ const std::string& interface_name,
const TestApi::Binder& binder) = 0;
virtual void ClearBinderOverrides() = 0;
};
« no previous file with comments | « content/test/BUILD.gn ('k') | services/service_manager/public/cpp/lib/connector_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698