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

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

Issue 2557213002: Build services as standalone executables (Closed)
Patch Set: remove DCHECKs with side effects -_- Created 4 years 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/public/cpp/service.h
diff --git a/services/service_manager/public/cpp/service.h b/services/service_manager/public/cpp/service.h
index 2b8e780d0b815c9bfad0241c168def0431467a70..b3322b200c10c2b55d60c2e9e5fc18f5c314ff0b 100644
--- a/services/service_manager/public/cpp/service.h
+++ b/services/service_manager/public/cpp/service.h
@@ -5,6 +5,8 @@
#ifndef SERVICES_SERVICE_MANAGER_PUBLIC_CPP_SERVICE_H_
#define SERVICES_SERVICE_MANAGER_PUBLIC_CPP_SERVICE_H_
+#include "base/macros.h"
+
namespace service_manager {
class InterfaceRegistry;
@@ -65,6 +67,8 @@ class Service {
void set_context(ServiceContext* context) { service_context_ = context; }
ServiceContext* service_context_ = nullptr;
+
+ DISALLOW_COPY_AND_ASSIGN(Service);
};
// TODO(rockot): Remove this. It's here to satisfy a few remaining use cases
@@ -75,14 +79,16 @@ class ForwardingService : public Service {
explicit ForwardingService(Service* target);
~ForwardingService() override;
- private:
// Service:
void OnStart() override;
bool OnConnect(const ServiceInfo& remote_info,
InterfaceRegistry* registry) override;
bool OnStop() override;
+ private:
Service* const target_ = nullptr;
+
+ DISALLOW_COPY_AND_ASSIGN(ForwardingService);
};
} // namespace service_manager
« no previous file with comments | « services/service_manager/public/cpp/lib/service_runner.cc ('k') | services/service_manager/public/cpp/service.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698