MeeGo 1.2 Harmattan Developer Documentation Develop for the Nokia N9
   Home · All Classes · All Namespaces · Modules · Functions · Files

cli-properties.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 PropertiesInterfaceInterface : public Tp::AbstractInterface
00045 {
00046     Q_OBJECT
00047 
00048 public:
00055     static inline QLatin1String staticInterfaceName()
00056     {
00057         return QLatin1String("org.freedesktop.Telepathy.Properties");
00058     }
00059 
00067     PropertiesInterfaceInterface(
00068         const QString& busName,
00069         const QString& objectPath,
00070         QObject* parent = 0
00071     );
00072 
00081     PropertiesInterfaceInterface(
00082         const QDBusConnection& connection,
00083         const QString& busName,
00084         const QString& objectPath,
00085         QObject* parent = 0
00086     );
00087 
00094     PropertiesInterfaceInterface(Tp::DBusProxy *proxy);
00095 
00103     explicit PropertiesInterfaceInterface(const Tp::AbstractInterface& mainInterface);
00104 
00112     PropertiesInterfaceInterface(const Tp::AbstractInterface& mainInterface, QObject* parent);
00113 
00120     Tp::PendingVariantMap *requestAllProperties() const
00121     {
00122         return internalRequestAllProperties();
00123     }
00124 
00125 public Q_SLOTS:
00151     inline QDBusPendingReply<Tp::PropertyValueList> GetProperties(const Tp::UIntList& properties, int timeout = -1)
00152     {
00153         if (!invalidationReason().isEmpty()) {
00154             return QDBusPendingReply<Tp::PropertyValueList>(QDBusMessage::createError(
00155                 invalidationReason(),
00156                 invalidationMessage()
00157             ));
00158         }
00159 
00160         QDBusMessage callMessage = QDBusMessage::createMethodCall(this->service(), this->path(),
00161                 this->staticInterfaceName(), QLatin1String("GetProperties"));
00162         callMessage << QVariant::fromValue(properties);
00163         return this->connection().asyncCall(callMessage, timeout);
00164     }
00165 
00182     inline QDBusPendingReply<Tp::PropertySpecList> ListProperties(int timeout = -1)
00183     {
00184         if (!invalidationReason().isEmpty()) {
00185             return QDBusPendingReply<Tp::PropertySpecList>(QDBusMessage::createError(
00186                 invalidationReason(),
00187                 invalidationMessage()
00188             ));
00189         }
00190 
00191         QDBusMessage callMessage = QDBusMessage::createMethodCall(this->service(), this->path(),
00192                 this->staticInterfaceName(), QLatin1String("ListProperties"));
00193         return this->connection().asyncCall(callMessage, timeout);
00194     }
00195 
00220     inline QDBusPendingReply<> SetProperties(const Tp::PropertyValueList& properties, int timeout = -1)
00221     {
00222         if (!invalidationReason().isEmpty()) {
00223             return QDBusPendingReply<>(QDBusMessage::createError(
00224                 invalidationReason(),
00225                 invalidationMessage()
00226             ));
00227         }
00228 
00229         QDBusMessage callMessage = QDBusMessage::createMethodCall(this->service(), this->path(),
00230                 this->staticInterfaceName(), QLatin1String("SetProperties"));
00231         callMessage << QVariant::fromValue(properties);
00232         return this->connection().asyncCall(callMessage, timeout);
00233     }
00234 
00235 Q_SIGNALS:
00253     void PropertiesChanged(const Tp::PropertyValueList& properties);
00254 
00272     void PropertyFlagsChanged(const Tp::PropertyFlagsChangeList& properties);
00273 
00274 protected:
00275     virtual void invalidate(Tp::DBusProxy *, const QString &, const QString &);
00276 };
00277 }
00278 }
00279 Q_DECLARE_METATYPE(Tp::Client::PropertiesInterfaceInterface*)

Copyright © 2008-2011 Collabora Ltd. and Nokia Corporation
Telepathy-Qt4 0.6.5