diff options
Diffstat (limited to 'doc/misc')
| -rw-r--r-- | doc/misc/ChangeLog | 4 | ||||
| -rw-r--r-- | doc/misc/dbus.texi | 51 |
2 files changed, 55 insertions, 0 deletions
diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 8cc9c082ce9..f9e81e8fc0f 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2010-08-23 Michael Albinus <michael.albinus@gmx.de> | ||
| 2 | |||
| 3 | * dbus.texi (Alternative Buses): New chapter. | ||
| 4 | |||
| 1 | 2010-08-12 Stefan Monnier <monnier@iro.umontreal.ca> | 5 | 2010-08-12 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 6 | ||
| 3 | * cl.texi (Mapping over Sequences): Rename mapc => cl-mapc. | 7 | * cl.texi (Mapping over Sequences): Rename mapc => cl-mapc. |
diff --git a/doc/misc/dbus.texi b/doc/misc/dbus.texi index 248884532df..f4f96d55391 100644 --- a/doc/misc/dbus.texi +++ b/doc/misc/dbus.texi | |||
| @@ -53,6 +53,7 @@ another. An overview of D-Bus can be found at | |||
| 53 | * Asynchronous Methods:: Calling methods non-blocking. | 53 | * Asynchronous Methods:: Calling methods non-blocking. |
| 54 | * Receiving Method Calls:: Offering own methods. | 54 | * Receiving Method Calls:: Offering own methods. |
| 55 | * Signals:: Sending and receiving signals. | 55 | * Signals:: Sending and receiving signals. |
| 56 | * Alternative Buses:: Alternative buses. | ||
| 56 | * Errors and Events:: Errors and events. | 57 | * Errors and Events:: Errors and events. |
| 57 | * Index:: Index including concepts, functions, variables. | 58 | * Index:: Index including concepts, functions, variables. |
| 58 | 59 | ||
| @@ -1579,6 +1580,56 @@ which objects the GNU/Linux @code{hal} daemon adds. | |||
| 1579 | @end defun | 1580 | @end defun |
| 1580 | 1581 | ||
| 1581 | 1582 | ||
| 1583 | @node Alternative Buses | ||
| 1584 | @chapter Alternative buses. | ||
| 1585 | @cindex bus names | ||
| 1586 | @cindex UNIX domain socket | ||
| 1587 | |||
| 1588 | Until now, we have spoken about the system and the session buses, | ||
| 1589 | which are the default buses to be connected to. However, it is | ||
| 1590 | possible to connect to any bus, from which the address is known. This | ||
| 1591 | is a UNIX domain socket. Everywhere, where a @var{bus} is mentioned | ||
| 1592 | as argument of a function (the symbol @code{:system} or the symbol | ||
| 1593 | @code{:session}), this address can be used instead. The connection to | ||
| 1594 | this bus must be initialized first. | ||
| 1595 | |||
| 1596 | @defun dbus-init-bus bus | ||
| 1597 | Establish the connection to D-Bus @var{bus}. | ||
| 1598 | |||
| 1599 | @var{bus} can be either the symbol @code{:system} or the symbol | ||
| 1600 | @code{:session}, or it can be a string denoting the address of the | ||
| 1601 | corresponding bus. For the system and session busses, this function | ||
| 1602 | is called when loading @file{dbus.el}, there is no need to call it | ||
| 1603 | again. | ||
| 1604 | |||
| 1605 | Example: You open another session bus in a terminal window on your host: | ||
| 1606 | |||
| 1607 | @example | ||
| 1608 | # eval `dbus-launch --auto-syntax` | ||
| 1609 | # echo $DBUS_SESSION_BUS_ADDRESS | ||
| 1610 | |||
| 1611 | @print{} unix:abstract=/tmp/dbus-JoFtAVG92w,guid=2f320a1ebe50b7ef58e | ||
| 1612 | @end example | ||
| 1613 | |||
| 1614 | In Emacs, you can access to this bus via its address: | ||
| 1615 | |||
| 1616 | @lisp | ||
| 1617 | (setq my-bus | ||
| 1618 | "unix:abstract=/tmp/dbus-JoFtAVG92w,guid=2f320a1ebe50b7ef58e") | ||
| 1619 | |||
| 1620 | @result{} "unix:abstract=/tmp/dbus-JoFtAVG92w,guid=2f320a1ebe50b7ef58e" | ||
| 1621 | |||
| 1622 | (dbus-init-bus my-bus) | ||
| 1623 | |||
| 1624 | @result{} nil | ||
| 1625 | |||
| 1626 | (dbus-get-unique-name my-bus) | ||
| 1627 | |||
| 1628 | @result{} ":1.0" | ||
| 1629 | @end lisp | ||
| 1630 | @end defun | ||
| 1631 | |||
| 1632 | |||
| 1582 | @node Errors and Events | 1633 | @node Errors and Events |
| 1583 | @chapter Errors and events. | 1634 | @chapter Errors and events. |
| 1584 | @cindex debugging | 1635 | @cindex debugging |