Next: Receiving Method Calls, Previous: Synchronous Methods, Up: Top [Contents][Index]
This function calls method on the D-Bus bus
asynchronously. bus is either the symbol :system
or the
symbol :session
.
service is the D-Bus service name to be used. path is the D-Bus object path, service is registered at. interface is an interface offered by service. It must provide method.
handler is a Lisp function, which is called when the
corresponding return message has arrived. If handler is
nil
, no return message will be expected.
If the parameter :timeout
is given, the following integer
timeout specifies the maximum number of milliseconds a reply
message must arrive. The default value is 25,000. If there is no
reply message in time, a D-Bus error is raised (see Errors and Events).
All other arguments args are passed to method as arguments. They are converted into D-Bus types as described in Type Conversion.
If handler is a Lisp function, the function returns a key into
the hash table dbus-registered-objects-table
. The
corresponding entry in the hash table is removed, when the return
message has been arrived, and handler is called. Example:
(dbus-call-method-asynchronously :system "org.freedesktop.Hal" "/org/freedesktop/Hal/devices/computer" "org.freedesktop.Hal.Device" "GetPropertyString" 'message "system.kernel.machine") ⇒ (:serial :system 2) -| i686