| CMakeLists.txt |
|
2845 |
- |
| dbus_minimal_p.h |
dbus-types.h |
11495 |
- |
| doc |
|
|
- |
| LICENSE.LIBDBUS-1.txt |
|
27248 |
- |
| qdbus_symbols.cpp |
|
3388 |
- |
| qdbus_symbols_p.h |
|
25542 |
- |
| qdbusabstractadaptor.cpp |
!
\class QDBusAbstractAdaptor
\inmodule QtDBus
\since 4.2
\brief The QDBusAbstractAdaptor class is the base class of D-Bus adaptor classes.
The QDBusAbstractAdaptor class is the starting point for all objects intending to provide
interfaces to the external world using D-Bus. This is accomplished by attaching a one or more
classes derived from QDBusAbstractAdaptor to a normal QObject and then registering that QObject
with QDBusConnection::registerObject. QDBusAbstractAdaptor objects are intended to be
light-weight wrappers, mostly just relaying calls into the real object (its parent) and the
signals from it.
Each QDBusAbstractAdaptor-derived class should define the D-Bus interface it is implementing
using the Q_CLASSINFO macro in the class definition. Note that only one interface can be
exposed in this way.
QDBusAbstractAdaptor uses the standard QObject mechanism of signals, slots and properties to
determine what signals, methods and properties to export to the bus. Any signal emitted by
QDBusAbstractAdaptor-derived classes will be automatically be relayed through any D-Bus
connections the object is registered on.
Classes derived from QDBusAbstractAdaptor must be created on the heap using the \a new operator
and must not be deleted by the user (they will be deleted automatically when the object they are
connected to is also deleted).
\sa {usingadaptors.html}{Using adaptors}, QDBusConnection
|
10500 |
- |
| qdbusabstractadaptor.h |
|
762 |
- |
| qdbusabstractadaptor_p.h |
|
2922 |
- |
| qdbusabstractinterface.cpp |
|
30375 |
- |
| qdbusabstractinterface.h |
|
4538 |
- |
| qdbusabstractinterface_p.h |
|
2237 |
- |
| qdbusargument.cpp |
|
36634 |
- |
| qdbusargument.h |
|
11795 |
- |
| qdbusargument_p.h |
|
5704 |
- |
| qdbusconnection.cpp |
!
\class QDBusConnection
\inmodule QtDBus
\since 4.2
\brief The QDBusConnection class represents a connection to the D-Bus bus daemon.
This class is the initial point in a D-Bus session. Using it, you
can get access to remote objects, interfaces; connect remote
signals to your object's slots; register objects, etc.
D-Bus connections are created using the connectToBus() function,
which opens a connection to the server daemon and does the initial
handshaking, associating that connection with a name. Further
attempts to connect using the same name will return the same
connection.
The connection is then torn down using the disconnectFromBus()
function.
Once disconnected, calling connectToBus() will not reestablish a
connection, you must create a new QDBusConnection instance.
As a convenience for the two most common connection types, the
sessionBus() and systemBus() functions return open connections to
the session server daemon and the system server daemon,
respectively. Those connections are opened when first used and are
closed when the QCoreApplication destructor is run.
D-Bus also supports peer-to-peer connections, without the need for
a bus server daemon. Using this facility, two applications can
talk to each other and exchange messages. This can be achieved by
passing an address to connectToBus() function, which was opened by
another D-Bus application using QDBusServer.
|
37583 |
- |
| qdbusconnection.h |
|
6849 |
- |
| qdbusconnection_p.h |
|
14449 |
- |
| qdbusconnectioninterface.cpp |
Implementation of interface class QDBusConnectionInterface
|
16131 |
- |
| qdbusconnectioninterface.h |
Proxy class for interface org.freedesktop.DBus
|
3240 |
- |
| qdbusconnectionmanager.cpp |
|
10355 |
- |
| qdbusconnectionmanager_p.h |
|
2395 |
- |
| qdbuscontext.cpp |
!
\since 4.3
\class QDBusContext
\inmodule QtDBus
\brief The QDBusContext class allows slots to determine the D-Bus context of the calls.
When a slot is called in an object due to a signal delivery or due
to a remote method call, it is sometimes necessary to know the
context in which that happened. In particular, if the slot
determines that it wants to send the reply at a later opportunity
or if it wants to reply with an error, the context is needed.
The QDBusContext class is an alternative to accessing the context
that doesn't involve modifying the code generated by the \l
{Qt D-Bus XML compiler (qdbusxml2cpp)}.
QDBusContext is used by subclassing it from the objects being
exported using QDBusConnection::registerObject(). The following
example illustrates the usage:
\snippet code/src_qdbus_qdbuscontext.cpp 0
The example illustrates the two typical uses, that of sending
error replies and that of delayed replies.
Note: do not subclass QDBusContext and QDBusAbstractAdaptor at the
same time. QDBusContext should appear in the real object, not the
adaptor. If it's necessary from the adaptor code to determine the
context, use a public inheritance and access the functions via
QObject::parent().
|
4998 |
- |
| qdbuscontext.h |
|
1132 |
- |
| qdbuscontext_p.h |
|
965 |
- |
| qdbusdemarshaller.cpp |
|
11217 |
- |
| qdbuserror.cpp |
!
\class QDBusError
\inmodule QtDBus
\since 4.2
\brief The QDBusError class represents an error received from the
D-Bus bus or from remote applications found in the bus.
When dealing with the D-Bus bus service or with remote
applications over D-Bus, a number of error conditions can
happen. This error conditions are sometimes signalled by a
returned error value or by a QDBusError.
C++ and Java exceptions are a valid analogy for D-Bus errors:
instead of returning normally with a return value, remote
applications and the bus may decide to throw an error
condition. However, the Qt D-Bus implementation does not use the C++
exception-throwing mechanism, so you will receive QDBusErrors in
the return reply (see QDBusReply::error()).
QDBusError objects are used to inspect the error name and message
as received from the bus and remote applications. You should not
create such objects yourself to signal error conditions when
called from D-Bus: instead, use QDBusMessage::createError() and
QDBusConnection::send().
\sa QDBusConnection::send(), QDBusMessage, QDBusReply
|
11136 |
- |
| qdbuserror.h |
|
2698 |
- |
| qdbusextratypes.cpp |
!
\fn QDebug QDBusObjectPath::operator<<(QDebug dbg, const QDBusObjectPath &path)
\since 6.8
Writes the contents of \a path to \a dbg.
|
5238 |
- |
| qdbusextratypes.h |
|
5106 |
- |
| qdbusintegrator.cpp |
|
104217 |
- |
| qdbusintegrator_p.h |
|
3944 |
- |
| qdbusinterface.cpp |
|
10349 |
- |
| qdbusinterface.h |
|
1135 |
- |
| qdbusinterface_p.h |
|
1066 |
- |
| qdbusinternalfilters.cpp |
|
20188 |
- |
| qdbusintrospection.cpp |
!
\class QDBusIntrospection
\inmodule QtDBus
\brief Information about introspected objects and interfaces on D-Bus.
\internal
This class provides structures and methods for parsing the XML introspection data for D-Bus.
Normally, you don't have to use the methods provided here: QDBusInterface and QDBusObject will
do that for you.
But they may prove useful if the XML data was obtained through other means (like parsing a file).
|
11287 |
- |
| qdbusintrospection_p.h |
|
4775 |
- |
| qdbusmarshaller.cpp |
|
16937 |
- |
| qdbusmessage.cpp |
!
\since 4.3
Returns the human-readable message associated with the error that was received.
|
28580 |
- |
| qdbusmessage.h |
|
3644 |
- |
| qdbusmessage_p.h |
|
2462 |
- |
| qdbusmetaobject.cpp |
|
23949 |
- |
| qdbusmetaobject_p.h |
|
1456 |
- |
| qdbusmetatype.cpp |
!
\class QDBusMetaType
\inmodule QtDBus
\brief Meta-type registration system for the Qt D-Bus module.
\internal
The QDBusMetaType class allows you to register class types for
marshalling and demarshalling over D-Bus. D-Bus supports a very
limited set of primitive types, but allows one to extend the type
system by creating compound types, such as arrays (lists) and
structs. In order to use them with Qt D-Bus, those types must be
registered.
See \l {qdbustypesystem.html}{Qt D-Bus Type System} for more
information on the type system and how to register additional
types.
\sa {qdbustypesystem.html}{Qt D-Bus Type System},
qDBusRegisterMetaType(), QMetaType, QVariant, QDBusArgument
|
13857 |
- |
| qdbusmetatype.h |
|
1447 |
- |
| qdbusmetatype_p.h |
|
1835 |
- |
| qdbusmisc.cpp |
|
7555 |
- |
| qdbuspendingcall.cpp |
!
\class QDBusPendingCall
\inmodule QtDBus
\ingroup shared
\since 4.5
\brief The QDBusPendingCall class refers to one pending asynchronous call.
A QDBusPendingCall object is a reference to a method call that was
sent over D-Bus without waiting for a reply. QDBusPendingCall is an
opaque type, meant to be used as a handle for a pending reply.
In most programs, the QDBusPendingCall class will not be used
directly. It can be safely replaced with the template-based
QDBusPendingReply, in order to access the contents of the reply or
wait for it to be complete.
The QDBusPendingCallWatcher class allows one to connect to a signal
that will indicate when the reply has arrived or if the call has
timed out. It also provides the
QDBusPendingCallWatcher::waitForFinished() method which will suspend
the execution of the program until the reply has arrived.
\note If you create a copy of a QDBusPendingCall object, all
information will be shared among the many copies. Therefore,
QDBusPendingCall is an explicitly-shared object and does not
provide a method of detaching the copies (since they refer
to the same pending call)
\sa QDBusPendingReply, QDBusPendingCallWatcher
|
17535 |
- |
| qdbuspendingcall.h |
|
2310 |
- |
| qdbuspendingcall_p.h |
|
2610 |
- |
| qdbuspendingreply.cpp |
!
\class QDBusPendingReply
\inmodule QtDBus
\since 4.5
\brief The QDBusPendingReply class contains the reply to an asynchronous method call.
The QDBusPendingReply is a variadic template class. The template parameters
are the types that will be used to extract the contents of the reply's data.
This class is similar in functionality to QDBusReply, but with two
important differences:
\list
\li QDBusReply accepts exactly one return type, whereas
QDBusPendingReply can have any number of types
\li QDBusReply only works on already completed replies, whereas
QDBusPendingReply allows one to wait for replies from pending
calls
\endlist
Where with QDBusReply you would write:
\snippet code/src_qdbus_qdbusreply.cpp 0
with QDBusPendingReply, the equivalent code (including the blocking
wait for the reply) would be:
\snippet code/src_qdbus_qdbuspendingreply.cpp 0
For method calls that have more than one output argument, with
QDBusReply, you would write:
\snippet code/src_qdbus_qdbusreply.cpp 1
whereas with QDBusPendingReply, all of the output arguments should
be template parameters:
\snippet code/src_qdbus_qdbuspendingreply.cpp 2
QDBusPendingReply objects can be associated with
QDBusPendingCallWatcher objects, which emit signals when the reply
arrives.
\sa QDBusPendingCallWatcher, QDBusReply
|
9461 |
- |
| qdbuspendingreply.h |
|
5122 |
- |
| qdbusreply.cpp |
!
\class QDBusReply
\inmodule QtDBus
\since 4.2
\brief The QDBusReply class stores the reply for a method call to a remote object.
QDBusReply\<T\> is a template class where \a T specifies the expected return type.
A QDBusReply object is a subset of the QDBusMessage object that represents a method call's
reply. It contains only the first output argument or the error code and is used by
QDBusInterface-derived classes to allow returning the error code as the function's return
argument.
It can be used in the following manner:
\snippet code/src_qdbus_qdbusreply.cpp 0
If the remote method call cannot fail, you can skip the error checking:
\snippet code/src_qdbus_qdbusreply.cpp 1
However, if it does fail under those conditions, the value returned by QDBusReply<T>::value() is
a default-constructed value. It may be indistinguishable from a valid return value.
QDBusReply objects are used for remote calls that have no output
arguments or return values (i.e., they have a "void" return
type). Use the isValid() function to test if the reply succeeded.
\sa QDBusMessage, QDBusInterface
|
7481 |
- |
| qdbusreply.h |
|
3349 |
- |
| qdbusserver.cpp |
!
\class QDBusServer
\inmodule QtDBus
\brief The QDBusServer class provides peer-to-peer communication
between processes on the same computer.
|
3634 |
- |
| qdbusserver.h |
|
1147 |
- |
| qdbusservicewatcher.cpp |
|
13468 |
- |
| qdbusservicewatcher.h |
|
2379 |
- |
| qdbusthreaddebug_p.h |
|
3582 |
- |
| qdbusunixfiledescriptor.cpp |
!
\class QDBusUnixFileDescriptor
\inmodule QtDBus
\ingroup shared
\since 4.8
\brief The QDBusUnixFileDescriptor class holds one Unix file descriptor.
The QDBusUnixFileDescriptor class is used to hold one Unix file
descriptor for use with the Qt D-Bus module. This allows applications to
send and receive Unix file descriptors over the D-Bus connection, mapping
automatically to the D-Bus type 'h'.
Objects of type QDBusUnixFileDescriptors can be used also as parameters
in signals and slots that get exported to D-Bus by registering with
QDBusConnection::registerObject.
QDBusUnixFileDescriptor does not take ownership of the file descriptor.
Instead, it will use the Unix system call \c dup(2) to make a copy of the
file descriptor. This file descriptor belongs to the
QDBusUnixFileDescriptor object and should not be stored or closed by the
user. Instead, you should make your own copy if you need that.
That copy is a real, open file descriptor for as long as the
QDBusUnixFileDescriptor object exists, so the object should be destroyed
as soon as it is no longer needed rather than kept alive indefinitely.
Holding many such objects for a long time, for example messages received
over D-Bus that carry a file descriptor and are then queued or cached by
the application, keeps that many file descriptors open and can exhaust
the process's file descriptor table.
\section1 Availability
Unix file descriptor passing is not available in all D-Bus connections.
This feature is present with D-Bus library and bus daemon version 1.4 and
upwards on Unix systems. Qt D-Bus automatically enables the feature if such
a version was found at compile-time and run-time.
To verify that your connection does support passing file descriptors,
check if the QDBusConnection::UnixFileDescriptorPassing capability is set
with QDBusConnection::connectionCapabilities(). If the flag is not
active, then you will not be able to make calls to methods that have
QDBusUnixFileDescriptor as arguments or even embed such a type in a
variant. You will also not receive calls containing that type.
Note also that remote applications may not have support for Unix file
descriptor passing. If you make a D-Bus to a remote application that
cannot receive such a type, you will receive an error reply. If you try
to send a signal containing a D-Bus file descriptor or return one from a
method call, the message will be silently dropped.
Even if the feature is not available, QDBusUnixFileDescriptor will
continue to operate, so code need not have compile-time checks for the
availability of this feature.
On non-Unix systems, QDBusUnixFileDescriptor will always report an
invalid state and QDBusUnixFileDescriptor::isSupported() will return
false.
\sa QDBusConnection::ConnectionCapabilities, QDBusConnection::connectionCapabilities()
|
9489 |
- |
| qdbusunixfiledescriptor.h |
|
1453 |
- |
| qdbusutil.cpp |
|
17508 |
- |
| qdbusutil_p.h |
|
5399 |
- |
| qdbusvirtualobject.cpp |
!
Constructs a QDBusVirtualObject with \a parent.
|
1760 |
- |
| qdbusvirtualobject.h |
|
864 |
- |
| qdbusxmlgenerator.cpp |
|
10033 |
- |
| qdbusxmlparser.cpp |
|
16823 |
- |
| qdbusxmlparser_p.h |
!
\internal
|
2130 |
- |
| qt_attribution.json |
|
959 |
- |
| Qt6DBusMacros.cmake |
|
8898 |
- |
| qtdbusglobal.h |
|
531 |
- |
| qtdbusglobal_p.h |
|
589 |
- |