Home · All Classes · All Namespaces · Modules · Functions · Files

cli-media-session-handler.h

00001 /*
00002  * This file contains D-Bus client proxy classes generated by qt4-client-gen.py.
00003  *
00004  * This file can be distributed under the same terms as the specification from
00005  * which it was generated.
00006  */
00007 
00008 #ifndef IN_TELEPATHY_QT4_HEADER
00009 #error IN_TELEPATHY_QT4_HEADER
00010 #endif
00011 
00012 #include <TelepathyQt4/Types>
00013 
00014 #include <QtGlobal>
00015 
00016 #include <QString>
00017 #include <QObject>
00018 #include <QVariant>
00019 
00020 #include <QDBusPendingReply>
00021 
00022 #include <TelepathyQt4/AbstractInterface>
00023 #include <TelepathyQt4/DBusProxy>
00024 
00025 // basically the same as GLib's G_GNUC_DEPRECATED
00026 #ifndef TELEPATHY_GNUC_DEPRECATED
00027 #   if defined(Q_CC_GNUC) && __GNUC__ >= 4
00028 #       define TELEPATHY_GNUC_DEPRECATED __attribute__((__deprecated__))
00029 #   else
00030 #       define TELEPATHY_GNUC_DEPRECATED
00031 #   endif
00032 #endif
00033 namespace Tp
00034 {
00035 namespace Client
00036 {
00037 
00045 class MediaSessionHandlerInterface : public Tp::AbstractInterface
00046 {
00047     Q_OBJECT
00048 
00049 public:
00056     static inline const char *staticInterfaceName()
00057     {
00058         return "org.freedesktop.Telepathy.Media.SessionHandler";
00059     }
00060 
00068     MediaSessionHandlerInterface(
00069         const QString& busName,
00070         const QString& objectPath,
00071         QObject* parent = 0
00072     );
00073 
00082     MediaSessionHandlerInterface(
00083         const QDBusConnection& connection,
00084         const QString& busName,
00085         const QString& objectPath,
00086         QObject* parent = 0
00087     );
00088 
00095     MediaSessionHandlerInterface(Tp::DBusProxy *proxy);
00096 
00097 public Q_SLOTS:
00106     inline QDBusPendingReply<> Error(uint errorCode, const QString& message)
00107     {
00108         if (!invalidationReason().isEmpty()) {
00109             return QDBusPendingReply<>(QDBusMessage::createError(
00110                 invalidationReason(),
00111                 invalidationMessage()
00112             ));
00113         }
00114 
00115 
00116         QList<QVariant> argumentList;
00117         argumentList << QVariant::fromValue(errorCode) << QVariant::fromValue(message);
00118         return asyncCallWithArgumentList(QLatin1String("Error"), argumentList);
00119     }
00120 
00128     inline QDBusPendingReply<> Ready()
00129     {
00130         if (!invalidationReason().isEmpty()) {
00131             return QDBusPendingReply<>(QDBusMessage::createError(
00132                 invalidationReason(),
00133                 invalidationMessage()
00134             ));
00135         }
00136 
00137 
00138         return asyncCall(QLatin1String("Ready"));
00139     }
00140 
00141 Q_SIGNALS:
00163     void NewStreamHandler(const QDBusObjectPath& streamHandler, uint ID, uint mediaType, uint direction);
00164 
00165 protected:
00166     virtual void invalidate(Tp::DBusProxy *, const QString &, const QString &);
00167 };
00168 }
00169 }


Copyright © 2009 Collabora Ltd. and Nokia Corporation
Telepathy-Qt4 0.1.10