qdbus:tldr:4766c
The qdbus
command is a command-line tool used on Unix-like operating systems (such as Linux) to interact with D-Bus, a message bus system that allows communication between applications running on the same system. D-Bus enables applications to publish, request, and exchange messages (method calls, signals, and properties) in a decentralized and asynchronous manner.
The qdbus
command provides a convenient way to explore the available D-Bus services, objects, interfaces, and methods on a system. It allows you to query, introspect, and execute D-Bus operations from the command line.
Typically, the syntax of the qdbus
command is as follows:
qdbus [OPTIONS] <command> <service> <path> <interface> <method|property|signal>
OPTIONS
are various command-line options that modify the behavior of theqdbus
command.<command>
specifies the operation to be performed, such aslist
,call
,introspect
, etc.<service>
represents the D-Bus service name.<path>
denotes the object path in D-Bus hierarchy.<interface>
specifies the interface (defined as XML) exposed by the service or object.<method|property|signal>
specifies the method, property, or signal name, depending on the<command>
.
For example, some commonly used qdbus
commands are:
qdbus --system
lists all the available D-Bus system services.qdbus --session
lists all the available D-Bus session services.qdbus --system org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus.ListNames
calls theListNames
method on the D-Bus service running on the system bus.qdbus --session org.example.Application /org/example/Application org.example.Application.someSignal
emits thesomeSignal
signal from the D-Bus service running on the session bus.
Overall, the qdbus
command provides a powerful way to interact with D-Bus services and perform various tasks related to D-Bus messaging and management.