summaryrefslogtreecommitdiffstats
path: root/dbus/bus.h
diff options
context:
space:
mode:
authorvlaviano@chromium.org <vlaviano@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-24 02:23:33 +0000
committervlaviano@chromium.org <vlaviano@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-24 02:23:33 +0000
commitf34dabdeb6ff9e25515bb68bac78af7f49ce6f3a (patch)
treefc6a84b0a3e496a0a7f52b2ad1559bd50f54908b /dbus/bus.h
parent89539dec77e9c1625d6616c4060b474e0ebd46bd (diff)
downloadchromium_src-f34dabdeb6ff9e25515bb68bac78af7f49ce6f3a.zip
chromium_src-f34dabdeb6ff9e25515bb68bac78af7f49ce6f3a.tar.gz
chromium_src-f34dabdeb6ff9e25515bb68bac78af7f49ce6f3a.tar.bz2
chrome: dbus: support asynchronous method replies
BUG=chromium-os:23241 TEST=Unit tests and manual testing on device. Change-Id: I4d665897687030f4ab2379e4f6ddb9b3ebe02af4 Review URL: http://codereview.chromium.org/8637002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@111479 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'dbus/bus.h')
-rw-r--r--dbus/bus.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/dbus/bus.h b/dbus/bus.h
index 89fba91..4af07ce 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,