8 #ifndef IN_TP_QT_HEADER
12 #include <TelepathyQt/Types>
20 #include <QDBusPendingReply>
22 #include <TelepathyQt/AbstractInterface>
23 #include <TelepathyQt/DBusProxy>
24 #include <TelepathyQt/Global>
29 class PendingOperation;
57 return QLatin1String(
"org.freedesktop.Telepathy.Media.SessionHandler");
68 const QString& busName,
69 const QString& objectPath,
82 const QDBusConnection& connection,
83 const QString& busName,
84 const QString& objectPath,
104 return internalRequestAllProperties();
121 inline QDBusPendingReply<>
Error(uint errorCode,
const QString& message,
int timeout = -1)
123 if (!invalidationReason().isEmpty()) {
124 return QDBusPendingReply<>(QDBusMessage::createError(
125 invalidationReason(),
126 invalidationMessage()
130 QDBusMessage callMessage = QDBusMessage::createMethodCall(this->service(), this->path(),
131 this->staticInterfaceName(), QLatin1String(
"Error"));
132 callMessage << QVariant::fromValue(errorCode) << QVariant::fromValue(message);
133 return this->connection().asyncCall(callMessage, timeout);
148 inline QDBusPendingReply<>
Ready(
int timeout = -1)
150 if (!invalidationReason().isEmpty()) {
151 return QDBusPendingReply<>(QDBusMessage::createError(
152 invalidationReason(),
153 invalidationMessage()
157 QDBusMessage callMessage = QDBusMessage::createMethodCall(this->service(), this->path(),
158 this->staticInterfaceName(), QLatin1String(
"Ready"));
159 return this->connection().asyncCall(callMessage, timeout);
184 void NewStreamHandler(
const QDBusObjectPath& streamHandler, uint ID, uint mediaType, uint direction);
187 virtual void invalidate(
Tp::DBusProxy *,
const QString &,
const QString &);
The DBusProxy class is a base class representing a remote object available over D-Bus.
Definition: dbus-proxy.h:42
QDBusPendingReply Ready(int timeout=-1)
Definition: cli-media-session-handler.h:148
static QLatin1String staticInterfaceName()
Definition: cli-media-session-handler.h:55
The AbstractInterface class is the base class for all client side D-Bus interfaces, allowing access to remote methods/properties/signals.
Definition: abstract-interface.h:42
QDBusPendingReply Error(uint errorCode, const QString &message, int timeout=-1)
Definition: cli-media-session-handler.h:121
Tp::PendingVariantMap * requestAllProperties() const
Definition: cli-media-session-handler.h:102
Definition: cli-media-session-handler.h:44
The PendingVariantMap class is a generic subclass of PendingOperation representing a pending D-Bus me...
Definition: pending-variant-map.h:38