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

Unified Diff: mojo/application/public/cpp/application_connection.h

Issue 1195003002: Mandoline: Introduce ApplicationConnection::CloseConnection (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added test Created 5 years, 6 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: mojo/application/public/cpp/application_connection.h
diff --git a/mojo/application/public/cpp/application_connection.h b/mojo/application/public/cpp/application_connection.h
index ff900d3668c7522e9fae35938adf5eded7b58167..4937fbfa57799405a3fd9325d2c94e87f7fe9a19 100644
--- a/mojo/application/public/cpp/application_connection.h
+++ b/mojo/application/public/cpp/application_connection.h
@@ -40,10 +40,16 @@ class ServiceConnector;
//
// Just as with InterfaceFactory, ServiceConnector must outlive
// ApplicationConnection.
+//
+// An ApplicationConnection's lifetime is managed by an ApplicationImpl. To
+// close a connection, call CloseConnection which will destroy this object.
class ApplicationConnection {
public:
virtual ~ApplicationConnection();
sky 2015/06/29 16:56:02 Can the destructor be made protected to prevent ac
Fady Samuel 2015/06/29 20:32:36 I took the following approach. 1. I made ~Applica
+ // Closes the connection.
+ virtual void CloseConnection() = 0;
+
// See class description for details.
virtual void SetServiceConnector(ServiceConnector* connector) = 0;

Powered by Google App Engine
This is Rietveld 408576698