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 #include <TelepathyQt4/Global>
00025 
00026 namespace Tp{
00027 class PendingVariant;
00028 class PendingOperation;
00029 }
00030 
00031 // FIXME: (API/ABI break) Remove definition of TELEPATHY_GNUC_DEPRECATED
00032 
00033 // basically the same as GLib's G_GNUC_DEPRECATED
00034 #ifndef TELEPATHY_GNUC_DEPRECATED
00035 #   if defined(Q_CC_GNUC) && __GNUC__ >= 4
00036 #       define TELEPATHY_GNUC_DEPRECATED __attribute__((__deprecated__))
00037 #   else
00038 #       define TELEPATHY_GNUC_DEPRECATED
00039 #   endif
00040 #endif
00041 namespace Tp
00042 {
00043 namespace Client
00044 {
00045 
00053 class TELEPATHY_QT4_EXPORT MediaSessionHandlerInterface : public Tp::AbstractInterface
00054 {
00055     Q_OBJECT
00056 
00057 public:
00064     static inline const char *staticInterfaceName()
00065     {
00066         return "org.freedesktop.Telepathy.Media.SessionHandler";
00067     }
00068 
00076     MediaSessionHandlerInterface(
00077         const QString& busName,
00078         const QString& objectPath,
00079         QObject* parent = 0
00080     );
00081 
00090     MediaSessionHandlerInterface(
00091         const QDBusConnection& connection,
00092         const QString& busName,
00093         const QString& objectPath,
00094         QObject* parent = 0
00095     );
00096 
00103     MediaSessionHandlerInterface(Tp::DBusProxy *proxy);
00104 
00111     Tp::PendingVariantMap *requestAllProperties() const
00112     {
00113         return internalRequestAllProperties();
00114     }
00115 
00116 public Q_SLOTS:
00125     inline QDBusPendingReply<> Error(uint errorCode, const QString& message)
00126     {
00127         if (!invalidationReason().isEmpty()) {
00128             return QDBusPendingReply<>(QDBusMessage::createError(
00129                 invalidationReason(),
00130                 invalidationMessage()
00131             ));
00132         }
00133 
00134         QList<QVariant> argumentList;
00135         argumentList << QVariant::fromValue(errorCode) << QVariant::fromValue(message);
00136         return asyncCallWithArgumentList(QLatin1String("Error"), argumentList);
00137     }
00138 
00146     inline QDBusPendingReply<> Ready()
00147     {
00148         if (!invalidationReason().isEmpty()) {
00149             return QDBusPendingReply<>(QDBusMessage::createError(
00150                 invalidationReason(),
00151                 invalidationMessage()
00152             ));
00153         }
00154 
00155         return asyncCall(QLatin1String("Ready"));
00156     }
00157 
00158 Q_SIGNALS:
00180     void NewStreamHandler(const QDBusObjectPath& streamHandler, uint ID, uint mediaType, uint direction);
00181 
00182 protected:
00183     virtual void invalidate(Tp::DBusProxy *, const QString &, const QString &);
00184 };
00185 }
00186 }
00187 Q_DECLARE_METATYPE(Tp::Client::MediaSessionHandlerInterface*)


Copyright © 2008-2010 Collabora Ltd. and Nokia Corporation
Telepathy-Qt4 0.4.4