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

Unified Diff: dbus/bus.h

Issue 8728020: chrome: dbus: support asynchronous method replies (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix comment Created 9 years, 1 month 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: dbus/bus.h
diff --git a/dbus/bus.h b/dbus/bus.h
index 89fba919fb35b279d7ef63551d26866db80b17eb..4af07ce1089fc2585a3c0eb6ff5dd040458e8600 100644
--- a/dbus/bus.h
+++ b/dbus/bus.h
@@ -100,11 +100,15 @@ class ObjectProxy;
//
// Exporting a method:
//
-// Response* Echo(dbus::MethodCall* method_call) {
+// void Echo(dbus::MethodCall* method_call,
+// dbus::ExportedObject::ResponseSender response_sender) {
// // Do something with method_call.
// Response* response = Response::FromMethodCall(method_call);
// // Build response here.
-// return response;
+// // Can send an immediate response here to implement a synchronous service
+// // or store the response_sender and send a response later to implement an
+// // asynchronous service.
+// response_sender.Run(response);
// }
//
// void OnExported(const std::string& interface_name,

Powered by Google App Engine
This is Rietveld 408576698