Mercurial > emacs
annotate doc/misc/dbus.texi @ 91205:75f33cb01d7c
(w32_to_x_font): Fix bad merge.
author | Jason Rumney <jasonr@gnu.org> |
---|---|
date | Thu, 06 Dec 2007 15:17:39 +0000 |
parents | f767f1ba8301 |
children | f10e4cb7d001 |
rev | line source |
---|---|
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
1 \input texinfo @c -*-texinfo-*- |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
2 @setfilename ../../info/dbus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
3 @c %**start of header |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
4 @settitle Using of D-Bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
5 @c @setchapternewpage odd |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
6 @c %**end of header |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
7 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
8 @copying |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
9 Copyright @copyright{} 2007 Free Software Foundation, Inc. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
10 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
11 @quotation |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
12 Permission is granted to copy, distribute and/or modify this document |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
13 under the terms of the GNU Free Documentation License, Version 1.2 or |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
14 any later version published by the Free Software Foundation; with no |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
15 Invariant Sections, with the Front-Cover texts being ``A GNU |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
16 Manual'', and with the Back-Cover Texts as in (a) below. A copy of the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
17 license is included in the section entitled ``GNU Free Documentation |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
18 License'' in the Emacs manual. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
19 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
20 (a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
21 this GNU Manual, like GNU software. Copies published by the Free |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
22 Software Foundation raise funds for GNU development.'' |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
23 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
24 This document is part of a collection distributed under the GNU Free |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
25 Documentation License. If you want to distribute this document |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
26 separately from the collection, you can do so by adding a copy of the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
27 license to the document, as described in section 6 of the license. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
28 @end quotation |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
29 @end copying |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
30 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
31 @dircategory Emacs |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
32 @direntry |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
33 * D-Bus: (dbus). Using D-Bus in Emacs. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
34 @end direntry |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
35 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
36 @node Top, Overview, (dir), (dir) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
37 @top D-Bus integration in Emacs |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
38 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
39 This manual documents an API for usage of D-Bus in |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
40 Emacs.@footnote{D-Bus is not enabled by default. You must run |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
41 @command{./configure --with-dbus} in Emacs' top level directory, |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
42 before you compile Emacs.} D-Bus is a message bus system, a simple |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
43 way for applications to talk to one another. An overview of D-Bus can |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
44 be found at @uref{http://dbus.freedesktop.org/}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
45 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
46 @insertcopying |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
47 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
48 @menu |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
49 * Overview:: An overview of D-Bus. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
50 * Inspection:: Inspection of the bus names. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
51 * Type Conversion:: Mapping Lisp types and D-Bus types. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
52 * Synchronous Methods:: Calling methods in a blocking way. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
53 * Signals:: Sending and receiving signals. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
54 * Errors and Events:: Errors and events. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
55 * GNU Free Documentation License:: The license for this documentation. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
56 @end menu |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
57 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
58 @node Overview |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
59 @chapter An overview of D-Bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
60 @cindex overview |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
61 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
62 D-Bus is an inter-process communication mechanism for applications |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
63 residing on the same host. The communication is based on |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
64 @dfn{messages}. Data in the messages is carried in a structured way, |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
65 it is not just a byte stream. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
66 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
67 The communication is connection oriented to two kinds of message |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
68 buses: a so called @dfn{system bus}, and a @dfn{session bus}. On a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
69 given machine, there is always one single system bus for miscellaneous |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
70 system-wide communication, like changing of hardware configuration. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
71 On the other hand, the session bus is always related to a single |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
72 user's session. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
73 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
74 Every client application, which is connected to a bus, registers under |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
75 a @dfn{unique name} at the bus. This name is used for identifying the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
76 client application. Such a unique name starts always with a colon, |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
77 and looks like @samp{:1.42}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
78 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
79 Additionally, a client application can register itself to a so called |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
80 @dfn{known name}, which is a series of identifiers separated by dots, |
86972
acea77e0ee56
(Overview): Minor cleanup.
Richard M. Stallman <rms@gnu.org>
parents:
86944
diff
changeset
|
81 as in @samp{org.gnu.Emacs}. If several applications register to the |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
82 same known name, these registrations are queued, and only the first |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
83 application which has registered for the known name is reachable via |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
84 this name. If this application disconnects from the bus, the next |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
85 queued unique name becomes the owner of this known name. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
86 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
87 An application can install one or several objects under its name. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
88 Such objects are identified by an @dfn{object path}, which looks |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
89 similar to paths in a filesystem. An example of such an object path |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
90 could be @samp{/org/gnu/Emacs/}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
91 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
92 Applications might send a request to an object, that means sending a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
93 message with some data as input parameters, and receiving a message |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
94 from that object with the result of this message, the output |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
95 parameters. Such a request is called @dfn{method} in D-Bus. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
96 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
97 The other form of communication are @dfn{signals}. The underlying |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
98 message is emitted from an object and will be received by all other |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
99 applications which have registered for such a signal. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
100 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
101 All methods and signals an object supports are called @dfn{interface} |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
102 of the object. Interfaces are specified under a hierarchical name in |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
103 D-Bus; an object can support several interfaces. Such an interface |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
104 name could be @samp{org.gnu.Emacs.TextEditor} or |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
105 @samp{org.gnu.Emacs.FileManager}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
106 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
107 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
108 @node Inspection |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
109 @chapter Inspection of the bus names. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
110 @cindex inspection |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
111 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
112 There are several basic functions which inspect the buses for |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
113 registered names. Internally they use the basic interface |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
114 @samp{org.freedesktop.DBus}, which is supported by all objects of a bus. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
115 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
116 @defun dbus-list-activatable-names |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
117 This function returns the D-Bus service names, which can be activated. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
118 An activatable service is described in a service registration file. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
119 Under GNU/Linux, such files are located at |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
120 @file{/usr/share/dbus-1/services/}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
121 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
122 The result is a list of strings, which is @code{nil} when there are no |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
123 activatable service names at all. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
124 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
125 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
126 @defun dbus-list-names bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
127 All service names, which are registered at D-Bus @var{bus}, are |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
128 returned. The result is a list of strings, which is @code{nil} when |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
129 there are no registered service names at all. Well known names are |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
130 strings like @samp{org.freedesktop.DBus}. Names starting with |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
131 @samp{:} are unique names for services. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
132 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
133 @var{bus} must be either the symbol @code{:system} or the symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
134 @code{:session}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
135 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
136 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
137 @defun dbus-list-known-names bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
138 Retrieves all services which correspond to a known name in @var{bus}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
139 A service has a known name if it doesn't start with @samp{:}. The |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
140 result is a list of strings, which is @code{nil} when there are no |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
141 known names at all. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
142 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
143 @var{bus} must be either the symbol @code{:system} or the symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
144 @code{:session}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
145 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
146 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
147 @defun dbus-list-queued-owners bus service |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
148 For a given service, registered at D-Bus @var{bus} under the name |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
149 @var{service}, all queued unique names are returned. The result is a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
150 list of strings, or @code{nil} when there are no queued names for |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
151 @var{service} at all. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
152 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
153 @var{bus} must be either the symbol @code{:system} or the symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
154 @code{:session}. @var{service} must be a known service name as |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
155 string. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
156 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
157 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
158 @defun dbus-get-name-owner bus service |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
159 For a given service, registered at D-Bus @var{bus} under the name |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
160 @var{service}, the unique name of the name owner is returned. The result is a |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
161 string, or @code{nil} when there exist no name owner of @var{service}. |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
162 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
163 @var{bus} must be either the symbol @code{:system} or the symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
164 @code{:session}. @var{service} must be a known service name as |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
165 string. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
166 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
167 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
168 @defun dbus-get-unique-name bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
169 The unique name, under which Emacs is registered at D-Bus @var{bus}, |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
170 is returned as string. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
171 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
172 @var{bus} must be either the symbol @code{:system} or the symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
173 @code{:session}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
174 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
175 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
176 @defun dbus-introspect bus service path |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
177 Objects can publish there interfaces to the D-Bus. This function |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
178 returns all interfaces of @var{service}, registered at object path |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
179 @var{path} at bus @var{bus}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
180 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
181 @var{bus} must be either the symbol @code{:system} or the symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
182 @code{:session}. @var{service} must be a known service name, and |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
183 @var{path} must be a valid object path. The last two parameters are |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
184 strings. The result, the introspection data, is a string in XML |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
185 format. Example: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
186 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
187 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
188 (dbus-introspect |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
189 :system "org.freedesktop.Hal" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
190 "/org/freedesktop/Hal/devices/computer") |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
191 |
86944
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
192 @result{} "<!DOCTYPE node PUBLIC |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
193 \"-//freedesktop//DTD D-BUS Object Introspection 1.0//EN\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
194 \"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd\"> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
195 <node> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
196 <interface name=\"org.freedesktop.Hal.Device\"> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
197 <method name=\"GetAllProperties\"> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
198 <arg name=\"properties\" direction=\"out\" type=\"a@{sv@}\"/> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
199 </method> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
200 ... |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
201 <signal name=\"PropertyModified\"> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
202 <arg name=\"num_updates\" type=\"i\"/> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
203 <arg name=\"updates\" type=\"a(sbb)\"/> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
204 </signal> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
205 </interface> |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
206 ... |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
207 </node>" |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
208 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
209 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
210 This example informs us, that the service @code{org.freedesktop.Hal} |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
211 at object path @code{/org/freedesktop/Hal/devices/computer} offers the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
212 interface @code{org.freedesktop.Hal.Device} (and 2 other interfaces |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
213 not documented here). This interface contains the method |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
214 @code{GetAllProperties}, which needs no input parameters, but returns |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
215 as output parameter an array of dictionary entries (key-value pairs). |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
216 Every dictionary entry has a string as key, and a variant as value. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
217 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
218 The interface offers also a signal, which returns 2 parameters: an |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
219 integer, and an array consisting of elements which are a struct of a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
220 string and 2 boolean values. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
221 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
222 Such type descriptions are called @dfn{signature} in D-Bus. For a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
223 discussion of D-Bus types and their Lisp representation see @ref{Type |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
224 Conversion}.@footnote{D-Bus signatures are explained in the D-Bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
225 specification |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
226 @uref{http://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-signatures}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
227 The interfaces of the service @code{org.freedesktop.Hal} are described |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
228 at |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
229 @uref{http://people.freedesktop.org/~david/hal-spec/hal-spec.html#interfaces}.} |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
230 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
231 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
232 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
233 @node Type Conversion |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
234 @chapter Mapping Lisp types and D-Bus types. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
235 @cindex type conversion |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
236 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
237 D-Bus method calls and signals accept usually several arguments as |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
238 parameters, either as input parameter, or as output parameter. Every |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
239 argument belongs to a D-Bus type. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
240 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
241 Such arguments must be mapped between the the value encoded as a D-Bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
242 type, and the corresponding type of Lisp objects. The mapping is |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
243 applied Lisp object @expansion{} D-Bus type for input parameters, and |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
244 D-Bus type @expansion{} Lisp object for output parameters. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
245 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
246 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
247 @section Input parameters. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
248 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
249 Input parameters for D-Bus methods and signals occur as arguments of a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
250 Lisp function call. Only some primitive Lisp types are supported in |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
251 the current implementation. The following mapping to D-Bus types is |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
252 applied, when the corresponding D-Bus message is created: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
253 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
254 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
255 @multitable {@code{t} and @code{nil}} {@expansion{}} {DBUS_TYPE_BOOLEAN} |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
256 @item Lisp type @tab @tab D-Bus type |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
257 @item |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
258 @item @code{t} and @code{nil} @tab @expansion{} @tab DBUS_TYPE_BOOLEAN |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
259 @item number @tab @expansion{} @tab DBUS_TYPE_UINT32 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
260 @item integer @tab @expansion{} @tab DBUS_TYPE_INT32 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
261 @item float @tab @expansion{} @tab DBUS_TYPE_DOUBLE |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
262 @item string @tab @expansion{} @tab DBUS_TYPE_STRING |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
263 @end multitable |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
264 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
265 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
266 @noindent |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
267 Other Lisp types, especially lists, are not supported (yet). |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
268 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
269 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
270 @section Output parameters. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
271 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
272 Output parameters of D-Bus methods and signals are mapped to Lisp |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
273 objects. This mapping is more powerful than the one for input |
86944
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
274 parameters, i.e., more D-Bus types are supported by the current |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
275 implementation. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
276 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
277 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
278 @multitable {DBUS_TYPE_OBJECT_PATH} {@expansion{}} {@code{t} or @code{nil}} |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
279 @item D-Bus type @tab @tab Lisp type |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
280 @item |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
281 @item DBUS_TYPE_BOOLEAN @tab @expansion{} @tab @code{t} or @code{nil} |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
282 @item DBUS_TYPE_UINT32 @tab @expansion{} @tab number |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
283 @item DBUS_TYPE_INT32 @tab @expansion{} @tab number |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
284 @item DBUS_TYPE_DOUBLE @tab @expansion{} @tab float |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
285 @item DBUS_TYPE_STRING @tab @expansion{} @tab string |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
286 @item DBUS_TYPE_OBJECT_PATH @tab @expansion{} @tab string |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
287 @item DBUS_TYPE_ARRAY @tab @expansion{} @tab list |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
288 @item DBUS_TYPE_VARIANT @tab @expansion{} @tab list |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
289 @item DBUS_TYPE_STRUCT @tab @expansion{} @tab list |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
290 @item DBUS_TYPE_DICT_ENTRY @tab @expansion{} @tab list |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
291 @end multitable |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
292 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
293 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
294 The resulting list of the last 4 D-Bus compound types contains as |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
295 elements the elements of the D-Bus container, mapped according to the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
296 same rules. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
297 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
298 The signal @code{PropertyModified}, discussed as example in |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
299 @ref{Inspection}, would offer as Lisp data the following object |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
300 (@var{BOOL} stands here for either @code{nil} or @code{t}): |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
301 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
302 @lisp |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
303 (@var{NUMBER} ((@var{STRING} @var{BOOL} @var{BOOL}) (@var{STRING} @var{BOOL} @var{BOOL}) ...)) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
304 @end lisp |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
305 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
306 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
307 @node Synchronous Methods |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
308 @chapter Calling methods in a blocking way. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
309 @cindex method calls, synchronous |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
310 @cindex synchronous method calls |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
311 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
312 Methods can be called synchronously (@dfn{blocking}) or asynchronously |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
313 (@dfn{non-blocking}). Currently, just synchronous methods are |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
314 implemented. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
315 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
316 At D-Bus level, a method call consist of two messages: one message |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
317 which carries the input parameters to the object owning the method to |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
318 be called, and a reply message returning the resulting output |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
319 parameters from the object. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
320 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
321 @defun dbus-call-method bus method service path interface &rest args |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
322 This function calls @var{method} on the D-Bus @var{bus}. @var{bus} is |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
323 either the symbol @code{:system} or the symbol @code{:session}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
324 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
325 @var{service} is the D-Bus service name to be used. @var{path} is the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
326 D-Bus object path, @var{service} is registered at. @var{interface} is |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
327 an interface offered by @var{service}. It must provide @var{method}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
328 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
329 All other arguments args are passed to @var{method} as arguments. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
330 They are converted into D-Bus types as described in @ref{Type |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
331 Conversion}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
332 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
333 The function returns the resulting values of @var{method} as a list of |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
334 Lisp objects, according to the type conversion rules described in |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
335 @ref{Type Conversion}. Example: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
336 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
337 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
338 (dbus-call-method |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
339 :session "GetKeyField" "org.gnome.seahorse" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
340 "/org/gnome/seahorse/keys/openpgp" "org.gnome.seahorse.Keys" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
341 "openpgp:657984B8C7A966DD" "simple-name") |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
342 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
343 @result{} (t ("Philip R. Zimmermann")) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
344 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
345 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
346 If the result of the method call is just one value, the converted Lisp |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
347 object is returned instead of a list containing this single Lisp |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
348 object. Example: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
349 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
350 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
351 (dbus-call-method |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
352 :system "GetPropertyString" "org.freedesktop.Hal" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
353 "/org/freedesktop/Hal/devices/computer" "org.freedesktop.Hal.Device" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
354 "system.kernel.machine") |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
355 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
356 @result{} "i686" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
357 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
358 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
359 With the @code{dbus-introspect} function it is possible to explore the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
360 interfaces of @samp{org.freedesktop.Hal} service. It offers the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
361 interfaces @samp{org.freedesktop.Hal.Manager} for the object at the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
362 path @samp{/org/freedesktop/Hal/Manager} as well as the interface |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
363 @samp{org.freedesktop.Hal.Device} for all objects prefixed with the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
364 path @samp{/org/freedesktop/Hal/devices}. With the methods |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
365 @samp{GetAllDevices} and @samp{GetAllProperties}, it is simple to |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
366 emulate the @code{lshal} command on GNU/Linux systems: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
367 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
368 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
369 (dolist (device |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
370 (dbus-call-method |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
371 :system "GetAllDevices" "org.freedesktop.Hal" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
372 "/org/freedesktop/Hal/Manager" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
373 "org.freedesktop.Hal.Manager")) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
374 (message "\nudi = %s" device) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
375 (dolist (properties |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
376 (dbus-call-method |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
377 :system "GetAllProperties" "org.freedesktop.Hal" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
378 device "org.freedesktop.Hal.Device")) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
379 (message " %s = %S" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
380 (car properties) (or (caar (cdr properties)) "")))) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
381 |
87004
0877a1d16074
* Makefile.in (INFO_TARGETS, DVI_TARGETS): Apply dbus and dbus.dvi
Michael Albinus <michael.albinus@gmx.de>
parents:
86972
diff
changeset
|
382 @print{} "udi = /org/freedesktop/Hal/devices/computer |
86944
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
383 info.addons = (\"hald-addon-acpi\") |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
384 info.bus = \"unknown\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
385 info.product = \"Computer\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
386 info.subsystem = \"unknown\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
387 info.udi = \"/org/freedesktop/Hal/devices/computer\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
388 linux.sysfs_path_device = \"(none)\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
389 power_management.acpi.linux.version = \"20051216\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
390 power_management.can_suspend_to_disk = t |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
391 power_management.can_suspend_to_ram = \"\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
392 power_management.type = \"acpi\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
393 smbios.bios.release_date = \"11/07/2001\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
394 system.chassis.manufacturer = \"COMPAL\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
395 system.chassis.type = \"Notebook\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
396 system.firmware.release_date = \"03/19/2005\" |
9ae2c39a9be6
* dbus.texi: Applying comments from RMS.
Michael Albinus <michael.albinus@gmx.de>
parents:
86942
diff
changeset
|
397 ..." |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
398 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
399 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
400 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
401 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
402 @node Signals |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
403 @chapter Sending and receiving signals. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
404 @cindex signals |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
405 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
406 Signals are broadcast messages. They carry input parameters, which |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
407 are received by all objects which have registered for such a signal. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
408 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
409 @defun dbus-send-signal bus signal service path interface &rest args |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
410 This function is similar to @code{dbus-call-method}. The difference |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
411 is, that there are no returning output parameters. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
412 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
413 The function emits @var{signal} on the D-Bus @var{bus}. @var{bus} is |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
414 either the symbol @code{:system} or the symbol @code{:session}. It |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
415 doesn't matter whether another object has registered for @var{signal}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
416 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
417 @var{service} is the D-Bus service name of the object the signal is |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
418 emitted from. @var{path} is the corresponding D-Bus object path, |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
419 @var{service} is registered at. @var{interface} is an interface |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
420 offered by @var{service}. It must provide @var{signal}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
421 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
422 All other arguments args are passed to @var{signal} as arguments. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
423 They are converted into D-Bus types as described in @ref{Type |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
424 Conversion}. Example: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
425 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
426 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
427 (dbus-send-signal |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
428 :session "FileModified" "org.gnu.Emacs" "/org/gnu/Emacs" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
429 "org.gnu.Emacs.FileManager" "/home/albinus/.emacs") |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
430 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
431 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
432 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
433 @defun dbus-register-signal bus signal service path interface handler |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
434 With this function, an application registers for @var{signal} on the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
435 D-Bus @var{bus}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
436 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
437 @var{bus} is either the symbol @code{:system} or the symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
438 @code{:session}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
439 |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
440 @var{service} is the D-Bus service name used by the sending D-Bus |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
441 object. It can be either a known name or the unique name of the D-Bus |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
442 object sending the signal. In case of a unique name, signals won't be |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
443 received any longer once the object owning this unique name has |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
444 disappeared, and a new queued object has replaced it. |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
445 |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
446 When @var{service} is @code{nil}, related signals from all D-Bus |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
447 objects shall be accepted. |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
448 |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
449 @var{path} is the corresponding D-Bus object path, @var{service} is |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
450 registered at. It can also be @code{nil} if the path name of incoming |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
451 signals shall not be checked. |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
452 |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
453 @var{interface} is an interface offered by @var{service}. It must |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
454 provide @var{signal}. |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
455 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
456 @var{handler} is a Lisp function to be called when the @var{signal} is |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
457 received. It must accept as arguments the output parameters |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
458 @var{signal} is sending. Example: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
459 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
460 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
461 (defun my-dbus-signal-handler (device) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
462 (message "Device %s added" device)) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
463 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
464 (dbus-register-signal |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
465 :system "DeviceAdded" |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
466 (dbus-get-name-owner :system "org.freedesktop.Hal") |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
467 "/org/freedesktop/Hal/Manager" "org.freedesktop.Hal.Manager" |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
468 'my-dbus-signal-handler) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
469 |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
470 @result{} (:system "org.freedesktop.Hal.Manager" "DeviceAdded") |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
471 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
472 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
473 As we know from the inspection data of interface |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
474 @code{org.freedesktop.Hal.Manager}, the signal @code{DeviceAdded} |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
475 provides one single parameter, which is mapped into a Lisp string. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
476 The callback function @code{my-dbus-signal-handler} must define one |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
477 single string argument therefore. Plugging an USB device to your |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
478 machine, when registered for signal @code{DeviceAdded}, will show you |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
479 which objects the GNU/Linux @code{hal} daemon adds. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
480 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
481 @code{dbus-register-signal} returns a Lisp symbol, which can be used |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
482 as argument in @code{dbus-unregister-signal} for removing the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
483 registration for @var{signal}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
484 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
485 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
486 @defun dbus-unregister-signal object |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
487 Unregister @var{object} from the the D-Bus. @var{object} must be the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
488 result of a preceding @code{dbus-register-signal} call. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
489 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
490 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
491 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
492 @node Errors and Events |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
493 @chapter Errors and events. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
494 @cindex errors |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
495 @cindex events |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
496 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
497 All errors raised by D-Bus are signaled with the error symbol |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
498 @code{dbus-error}. As usual, such an error can be trapped with a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
499 @code{condition-case} form. If possible, error messages from D-Bus |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
500 are appended to the @code{dbus-error}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
501 |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
502 Incoming D-Bus messages are handled as Emacs events (see @pxref{Misc |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
503 Events, , , elisp}). The generated event has this form: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
504 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
505 @example |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
506 (dbus-event @var{handler} @var{bus} @var{service} @var{path} @var{interface} @var{member} &rest @var{args}) |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
507 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
508 |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
509 @var{handler} is the callback function which has been registered for |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
510 this signal (see @pxref{Signals}). When a @code{dbus-event} event |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
511 arrives, @var{handler} is called with @var{args} as arguments. |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
512 |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
513 @var{bus} identifies the D-Bus the signal is coming from. It is |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
514 either the symbol @code{:system} or the symbol @code{:session}. |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
515 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
516 @var{service} and @var{path} are the unique name and the object path |
87049
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
517 of the D-Bus object emitting the signal. @var{interface} and |
cbcfa9b4201e
* dbus.texi (Signals): Precise `dbus-register-signal'.
Michael Albinus <michael.albinus@gmx.de>
parents:
87004
diff
changeset
|
518 @var{member} denote the signal which has been sent. |
86942
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
519 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
520 In order to inspect the @code{dbus-event} data, you could extend the |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
521 definition of the callback function in @ref{Signals}: |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
522 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
523 @example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
524 (defun my-dbus-signal-handler (&rest args) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
525 (message "my-dbus-signal-handler: %S" last-input-event)) |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
526 @end example |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
527 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
528 There exist convenience functions which could be called inside a |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
529 callback function in order to retrieve the information from the event. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
530 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
531 @defun dbus-event-bus-name event |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
532 Returns the bus name @var{event} is coming from. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
533 The result is either the symbol @code{:system} or the symbol @code{:session}. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
534 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
535 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
536 @defun dbus-event-service-name event |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
537 Returns the unique name of the D-Bus object @var{event} is coming from. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
538 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
539 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
540 @defun dbus-event-path-name event |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
541 Returns the object path of the D-Bus object @var{event} is coming from. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
542 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
543 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
544 @defun dbus-event-interface-name event |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
545 Returns the interface name of of the D-Bus object @var{event} is coming from. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
546 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
547 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
548 @defun dbus-event-member-name event |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
549 Returns the member name of of the D-Bus object @var{event} is coming |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
550 from. It is either a signal name or a method name. |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
551 @end defun |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
552 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
553 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
554 @node GNU Free Documentation License |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
555 @appendix GNU Free Documentation License |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
556 @include doclicense.texi |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
557 |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
558 @contents |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
559 @c End of dbus.texi |
2fa0494ae318
* dbus.texi: New file.
Michael Albinus <michael.albinus@gmx.de>
parents:
diff
changeset
|
560 @bye |
87053 | 561 |
562 @ignore | |
563 arch-tag: 2eeec19d-0caf-44e0-a193-329d7f9951d8 | |
564 @end ignore |