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

Unified Diff: services/service_manager/tests/connect/connect_test_app.cc

Issue 2435153004: Change Service contract to pass ServiceInfo instead of Identity (Closed)
Patch Set: . Created 4 years, 2 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
Index: services/service_manager/tests/connect/connect_test_app.cc
diff --git a/services/service_manager/tests/connect/connect_test_app.cc b/services/service_manager/tests/connect/connect_test_app.cc
index b8f469ccbef68c5470c8253f34c8726a216e0268..78ba1e498dbdf5f23ae4f1bc0d38b1b44a7c11f2 100644
--- a/services/service_manager/tests/connect/connect_test_app.cc
+++ b/services/service_manager/tests/connect/connect_test_app.cc
@@ -53,8 +53,8 @@ class ConnectTestApp : public Service,
private:
// service_manager::Service:
- void OnStart(const Identity& identity) override {
- identity_ = identity;
+ void OnStart(const ServiceInfo& info) override {
+ identity_ = info.identity;
bindings_.set_connection_error_handler(
base::Bind(&ConnectTestApp::OnConnectionError,
base::Unretained(this)));
@@ -62,7 +62,7 @@ class ConnectTestApp : public Service,
base::Bind(&ConnectTestApp::OnConnectionError,
base::Unretained(this)));
}
- bool OnConnect(const Identity& remote_identity,
+ bool OnConnect(const ServiceInfo& remote_info,
InterfaceRegistry* registry) override {
registry->AddInterface<test::mojom::ConnectTestService>(this);
registry->AddInterface<test::mojom::StandaloneApp>(this);
@@ -70,12 +70,12 @@ class ConnectTestApp : public Service,
registry->AddInterface<test::mojom::UserIdTest>(this);
test::mojom::ConnectionStatePtr state(test::mojom::ConnectionState::New());
- state->connection_remote_name = remote_identity.name();
- state->connection_remote_userid = remote_identity.user_id();
+ state->connection_remote_name = remote_info.identity.name();
+ state->connection_remote_userid = remote_info.identity.user_id();
state->initialize_local_name = identity_.name();
state->initialize_userid = identity_.user_id();
- connector()->ConnectToInterface(remote_identity, &caller_);
+ connector()->ConnectToInterface(remote_info.identity, &caller_);
caller_->ConnectionAccepted(std::move(state));
return true;
« no previous file with comments | « services/service_manager/service_manager.cc ('k') | services/service_manager/tests/connect/connect_test_class_app.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698