Skip to content

Commit 5860a6b

Browse files
committed
Use consistent D-Bus spelling for documentation
D-Bus in documentation but code can use either dbus or Dbus.
1 parent ae7bda2 commit 5860a6b

21 files changed

+186
-186
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Features:
1010
* No Python 2 legacy.
1111
* Based on fast sd-bus from systemd. (also supports elogind)
1212
* Unified client/server interface classes. Write interface once!
13-
* Dbus methods can have keyword and default arguments.
13+
* D-Bus methods can have keyword and default arguments.
1414

1515
See the
1616
[documentation](https://python-sdbus.readthedocs.io/en/latest/index.html)
@@ -157,7 +157,7 @@ async def startup() -> None:
157157
# Acquire a known name on the bus
158158
# Clients will use that name to address this server
159159
await request_default_bus_name_async('org.example.test')
160-
# Export the object to dbus
160+
# Export the object to D-Bus
161161
export_object.export_to_dbus('/')
162162

163163

docs/asyncio_api.rst

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -8,28 +8,28 @@ Classes
88
99
.. py:class:: DbusInterfaceCommonAsync(interface_name)
1010
11-
Dbus async interface class.
12-
Dbus methods and properties should be defined using
11+
D-Bus async interface class.
12+
D-Bus methods and properties should be defined using
1313
:py:func:`dbus_property_async`, :py:func:`dbus_signal_async`,
1414
and :py:func:`dbus_method_async` decorators.
1515

1616
.. note::
1717
Don't forget to call ``super().__init__()`` in derived classes
1818
init calls as it sets up important attributes.
1919

20-
:param str interface_name: Sets the dbus interface
20+
:param str interface_name: Sets the D-Bus interface
2121
name that will be used for all properties, methods
2222
and signals defined in the body of the class.
2323

2424
:param bool serving_enabled: If set to :py:obj:`True`
25-
the interface will not be served on dbus. Mostly used
25+
the interface will not be served on D-Bus. Mostly used
2626
for interfaces that sd-bus already provides such as
2727
``org.freedesktop.DBus.Peer``.
2828

2929
.. py:method:: dbus_ping()
3030
:async:
3131

32-
Pings the remote service using dbus.
32+
Pings the remote service using D-Bus.
3333

3434
Useful to test if connection or remote service is alive.
3535

@@ -47,7 +47,7 @@ Classes
4747
.. py:method:: dbus_introspect()
4848
:async:
4949

50-
Get dbus introspection XML.
50+
Get D-Bus introspection XML.
5151

5252
It is users responsibility to parse that data.
5353

@@ -92,50 +92,50 @@ Classes
9292

9393
.. py:method:: _proxify(bus, service_name, object_path)
9494
95-
Begin proxying to a remote dbus object.
95+
Begin proxying to a remote D-Bus object.
9696

9797
:param str service_name:
98-
Remote object dbus connection name.
98+
Remote object D-Bus connection name.
9999
For example, systemd uses ``org.freedesktop.systemd1``
100100

101101
:param str object_path:
102-
Remote object dbus path.
102+
Remote object D-Bus path.
103103
Should be a forward slash separated path.
104104
Starting object is usually ``/``.
105105
Example: ``/org/freedesktop/systemd/unit/dbus_2eservice``
106106

107107
:param SdBus bus:
108-
Optional dbus connection object.
109-
If not passed the default dbus will be used.
108+
Optional D-Bus connection object.
109+
If not passed the default D-Bus will be used.
110110

111111
.. py:classmethod:: new_proxy(bus, service_name, object_path)
112112
113113
Create new proxy object and bypass ``__init__``.
114114

115115
:param str service_name:
116-
Remote object dbus connection name.
116+
Remote object D-Bus connection name.
117117
For example, systemd uses ``org.freedesktop.systemd1``
118118

119119
:param str object_path:
120-
Remote object dbus path.
120+
Remote object D-Bus path.
121121
Should be a forward slash separated path.
122122
Starting object is usually ``/``.
123123
Example: ``/org/freedesktop/systemd/unit/dbus_2eservice``
124124

125125
:param SdBus bus:
126-
Optional dbus connection object.
127-
If not passed the default dbus will be used.
126+
Optional D-Bus connection object.
127+
If not passed the default D-Bus will be used.
128128

129129
.. py:method:: export_to_dbus(object_path, bus)
130130
131-
Object will appear and become callable on dbus.
131+
Object will appear and become callable on D-Bus.
132132

133133
:param str object_path:
134134
Object path that it will be available at.
135135

136136
:param SdBus bus:
137-
Optional dbus connection object.
138-
If not passed the default dbus will be used.
137+
Optional D-Bus connection object.
138+
If not passed the default D-Bus will be used.
139139

140140

141141
.. py:class:: DbusObjectManagerInterfaceAsync(interface_name)
@@ -218,8 +218,8 @@ Classes
218218
Object to export to D-Bus.
219219

220220
:param SdBus bus:
221-
Optional dbus connection object.
222-
If not passed the default dbus will be used.
221+
Optional D-Bus connection object.
222+
If not passed the default D-Bus will be used.
223223

224224
:raises RuntimeError: ObjectManager was not exported.
225225

@@ -248,11 +248,11 @@ Decorators
248248

249249
Underlying function must be a coroutine function.
250250

251-
:param str input_signature: dbus input signature.
251+
:param str input_signature: D-Bus input signature.
252252
Defaults to "" meaning method takes no arguments.
253253
Required if you intend to connect to a remote object.
254254

255-
:param str result_signature: dbus result signature.
255+
:param str result_signature: D-Bus result signature.
256256
Defaults to "" meaning method returns empty reply on success.
257257
Required if you intend to serve the object.
258258

@@ -290,7 +290,7 @@ Decorators
290290
argument names will be used otherwise input arguments
291291
will be nameless
292292

293-
:param str method_name: Force specific dbus method name
293+
:param str method_name: Force specific D-Bus method name
294294
instead of being based on Python function name.
295295

296296
Example: ::
@@ -318,7 +318,7 @@ Decorators
318318

319319
.. py:decorator:: dbus_property_async(property_signature, [flags, [property_name]])
320320
321-
Declare a dbus property.
321+
Declare a D-Bus property.
322322

323323
The underlying function has to be a regular ``def`` function.
324324

@@ -331,7 +331,7 @@ Decorators
331331
does not perform heavy IO or computation
332332
as that will block other methods or properties.
333333

334-
:param str property_signature: Property dbus signature.
334+
:param str property_signature: Property D-Bus signature.
335335
Has to be a single type or container.
336336

337337
:param int flags: modifies behavior.
@@ -407,11 +407,11 @@ Decorators
407407

408408
.. py:decorator:: dbus_signal_async([signal_signature, [signal_args_names, [flags, [signal_name]]]])
409409
410-
Defines a dbus signal.
410+
Defines a D-Bus signal.
411411

412412
Underlying function return type hint is used for signal type hints.
413413

414-
:param str signal_signature: signal dbus signature.
414+
:param str signal_signature: signal D-Bus signature.
415415
Defaults to empty signal.
416416

417417
:param Sequence[str] signal_args_names: sequence of signal argument names.
@@ -466,7 +466,7 @@ Decorators
466466
the service name of the proxy will be used.
467467

468468
:param str bus:
469-
Optional dbus connection object.
469+
Optional D-Bus connection object.
470470
If not passed when called from proxy the bus connected
471471
to proxy will be used or when called from class default
472472
bus will be used.

docs/asyncio_quick.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ Python-sdbus works by declaring interface classes.
1010

1111
Interface classes for async IO should be derived from :py:class:`DbusInterfaceCommonAsync`.
1212

13-
The class constructor takes ``interface_name`` keyword to determine the dbus interface name for all
14-
dbus elements declared in the class body.
13+
The class constructor takes ``interface_name`` keyword to determine the D-Bus interface name for all
14+
D-Bus elements declared in the class body.
1515

1616
Example: ::
1717

@@ -77,14 +77,14 @@ Recommended to create proxy classes that a subclass of the interface: ::
7777
self._proxify('org.example.test', '/')
7878

7979

80-
.. note:: Successfully initiating a proxy object does NOT guarantee that the dbus object exists.
80+
.. note:: Successfully initiating a proxy object does NOT guarantee that the D-Bus object exists.
8181

8282
Serving objects
8383
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
8484

8585
:py:meth:`DbusInterfaceCommonAsync.export_to_dbus` method
86-
will export the object to the dbus. After calling it the object
87-
becomes visible on dbus for other processes to call.
86+
will export the object to the D-Bus. After calling it the object
87+
becomes visible on D-Bus for other processes to call.
8888

8989
Example using ExampleInterface from before: ::
9090

@@ -238,7 +238,7 @@ Example: ::
238238
Signals
239239
^^^^^^^^^^^^^^^^^^^^^^^^^^^
240240

241-
To define a dbus signal wrap a function with :py:func:`dbus_signal_async` decorator.
241+
To define a D-Bus signal wrap a function with :py:func:`dbus_signal_async` decorator.
242242

243243
The function is only used for type hints information. It is recommended
244244
to just put ``raise NotImplementedError`` in to the body of the function.
@@ -286,7 +286,7 @@ Example::
286286
Subclass Overrides
287287
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
288288

289-
If you define a subclass which overrides a declared dbus method or property
289+
If you define a subclass which overrides a declared D-Bus method or property
290290
you need to use :py:func:`dbus_method_async_override` and :py:func:`dbus_property_async_override`
291291
decorators. Overridden property can decorate a new setter.
292292

@@ -318,7 +318,7 @@ Example: ::
318318
Multiple interfaces
319319
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
320320

321-
A dbus object can have multiple interfaces with different methods and properties.
321+
A D-Bus object can have multiple interfaces with different methods and properties.
322322

323323
To implement this define multiple interface classes and do a
324324
multiple inheritance on all interfaces the object has.

docs/autodoc.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Autodoc extensions
22
==================
33

44
Python-sdbus has an extension for Sphinx autodoc that can
5-
document dbus interfaces.
5+
document D-Bus interfaces.
66

77
To use it include ``"sdbus.autodoc"`` extension in your
88
``conf.py`` file.
@@ -22,16 +22,16 @@ uses it to document the classes.
2222
2323
.. warning:: Autodoc extension is early in development and
2424
has multiple issues. For example, the inheritance ``:inherited-members:``
25-
does not work on the dbus elements.
25+
does not work on the D-Bus elements.
2626

2727
Writing docstrings
2828
-------------------
2929

30-
The dbus methods should be documented same way as the regular function
30+
The D-Bus methods should be documented same way as the regular function
3131
would. See `Sphinx documentation on possible fields \
3232
<https://www.sphinx-doc.org/en/master/usage/restructuredtext/domains.html#info-field-lists>`_
3333

34-
Example docstring for a dbus method:
34+
Example docstring for a D-Bus method:
3535

3636
.. code-block:: python
3737
@@ -45,14 +45,14 @@ Example docstring for a dbus method:
4545
"""
4646
raise NotImplementedError
4747
48-
Dbus properties and signals will be annotated with type taken from the
48+
D-Bus properties and signals will be annotated with type taken from the
4949
stub function.
5050

5151
.. code-block:: python
5252
5353
@dbus_property_async('as')
5454
def features(self) -> List[str]:
55-
"""List of dbus daemon features.
55+
"""List of D-Bus daemon features.
5656
5757
Features include:
5858
@@ -61,7 +61,7 @@ stub function.
6161
header fields.
6262
* 'SELinux' - Messages filtered by SELinux on this bus.
6363
* 'SystemdActivation' - services activated by systemd if their \
64-
.service file specifies a dbus name.
64+
.service file specifies a D-Bus name.
6565
"""
6666
raise NotImplementedError
6767

docs/common_api.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ These calls are shared between async and blocking API.
55

66
.. py:currentmodule:: sdbus
77
8-
Dbus connections calls
8+
D-Bus connections calls
99
++++++++++++++++++++++++++++++++++
1010

1111
.. py:function:: request_default_bus_name_async(new_name, allow_replacement, replace_existing, queue)
@@ -14,9 +14,9 @@ Dbus connections calls
1414
Acquire a name on the default bus async.
1515

1616
:param str new_name: the name to acquire.
17-
Must be a valid dbus service name.
17+
Must be a valid D-Bus service name.
1818
:param str new_name: the name to acquire.
19-
Must be a valid dbus service name.
19+
Must be a valid D-Bus service name.
2020
:param bool allow_replacement: If name was acquired allow other peers
2121
to take away the name.
2222
:param bool replace_existing: If current name owner allows, take
@@ -32,7 +32,7 @@ Dbus connections calls
3232
Acquire a name on the default bus.
3333

3434
:param str new_name: the name to acquire.
35-
Must be a valid dbus service name.
35+
Must be a valid D-Bus service name.
3636
:param bool allow_replacement: If name was acquired allow other peers
3737
to take away the name.
3838
:param bool replace_existing: If current name owner allows, take
@@ -120,13 +120,13 @@ Helper functions
120120
:return: valid object path
121121
:rtype: str
122122

123-
Example on how systemd encodes unit names on dbus: ::
123+
Example on how systemd encodes unit names on D-Bus: ::
124124

125125
from sdbus import encode_object_path
126126

127127

128128
# System uses /org/freedesktop/systemd1/unit as prefix of all units
129-
# dbus.service is a name of dbus unit but dot . is not a valid object path
129+
# dbus.service is a name of D-Bus unit but dot . is not a valid object path
130130
s = encode_object_path('/org/freedesktop/systemd1/unit', 'dbus.service')
131131
print(s)
132132
# Prints: /org/freedesktop/systemd1/unit/dbus_2eservice

docs/examples.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ There are 3 files:
7474
# Acquire a known name on the bus
7575
# Clients will use that name to address to this server
7676
await request_default_bus_name_async('org.example.test')
77-
# Export the object to dbus
77+
# Export the object to D-Bus
7878
export_object.export_to_dbus('/')
7979

8080

0 commit comments

Comments
 (0)