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 &);