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

cli-channel-dispatcher.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 {
00028 class PendingVariant;
00029 class PendingOperation;
00030 }
00031 
00032 namespace Tp
00033 {
00034 namespace Client
00035 {
00036 
00044 class TELEPATHY_QT4_EXPORT ChannelDispatcherInterface : public Tp::AbstractInterface
00045 {
00046     Q_OBJECT
00047 
00048 public:
00055     static inline QLatin1String staticInterfaceName()
00056     {
00057         return QLatin1String("org.freedesktop.Telepathy.ChannelDispatcher");
00058     }
00059 
00067     ChannelDispatcherInterface(
00068         const QString& busName,
00069         const QString& objectPath,
00070         QObject* parent = 0
00071     );
00072 
00081     ChannelDispatcherInterface(
00082         const QDBusConnection& connection,
00083         const QString& busName,
00084         const QString& objectPath,
00085         QObject* parent = 0
00086     );
00087 
00094     ChannelDispatcherInterface(Tp::DBusProxy *proxy);
00095 
00105     inline Tp::PendingVariant *requestPropertyInterfaces() const
00106     {
00107         return internalRequestProperty(QLatin1String("Interfaces"));
00108     }
00109 
00116     Tp::PendingVariantMap *requestAllProperties() const
00117     {
00118         return internalRequestAllProperties();
00119     }
00120 
00121 public Q_SLOTS:
00240     inline QDBusPendingReply<QDBusObjectPath> CreateChannel(const QDBusObjectPath& account, const QVariantMap& requestedProperties, qlonglong userActionTime, const QString& preferredHandler, int timeout = -1)
00241     {
00242         if (!invalidationReason().isEmpty()) {
00243             return QDBusPendingReply<QDBusObjectPath>(QDBusMessage::createError(
00244                 invalidationReason(),
00245                 invalidationMessage()
00246             ));
00247         }
00248 
00249         QDBusMessage callMessage = QDBusMessage::createMethodCall(this->service(), this->path(),
00250                 this->staticInterfaceName(), QLatin1String("CreateChannel"));
00251         callMessage << QVariant::fromValue(account) << QVariant::fromValue(requestedProperties) << QVariant::fromValue(userActionTime) << QVariant::fromValue(preferredHandler);
00252         return this->connection().asyncCall(callMessage, timeout);
00253     }
00254 
00346     inline QDBusPendingReply<QDBusObjectPath> EnsureChannel(const QDBusObjectPath& account, const QVariantMap& requestedProperties, qlonglong userActionTime, const QString& preferredHandler, int timeout = -1)
00347     {
00348         if (!invalidationReason().isEmpty()) {
00349             return QDBusPendingReply<QDBusObjectPath>(QDBusMessage::createError(
00350                 invalidationReason(),
00351                 invalidationMessage()
00352             ));
00353         }
00354 
00355         QDBusMessage callMessage = QDBusMessage::createMethodCall(this->service(), this->path(),
00356                 this->staticInterfaceName(), QLatin1String("EnsureChannel"));
00357         callMessage << QVariant::fromValue(account) << QVariant::fromValue(requestedProperties) << QVariant::fromValue(userActionTime) << QVariant::fromValue(preferredHandler);
00358         return this->connection().asyncCall(callMessage, timeout);
00359     }
00360 
00361 protected:
00362     virtual void invalidate(Tp::DBusProxy *, const QString &, const QString &);
00363 };
00364 }
00365 }
00366 Q_DECLARE_METATYPE(Tp::Client::ChannelDispatcherInterface*)


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