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

# cli-connection-manager.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 // basically the same as GLib's G_GNUC_DEPRECATED
    00027 #ifndef TELEPATHY_GNUC_DEPRECATED
    00028 #   if defined(Q_CC_GNUC) && __GNUC__ >= 4
    00029 #       define TELEPATHY_GNUC_DEPRECATED __attribute__((__deprecated__))
    00030 #   else
    00031 #       define TELEPATHY_GNUC_DEPRECATED
    00032 #   endif
    00033 #endif
    00034 namespace Tp
    00035 {
    00036 namespace Client
    00037 {
    00038
    00046 class TELEPATHY_QT4_EXPORT ConnectionManagerInterface : public Tp::AbstractInterface
    00047 {
    00048     Q_OBJECT
    00049
    00050 public:
    00057     static inline const char *staticInterfaceName()
    00058     {
    00059         return "org.freedesktop.Telepathy.ConnectionManager";
    00060     }
    00061
    00069     ConnectionManagerInterface(
    00070         const QString& busName,
    00071         const QString& objectPath,
    00072         QObject* parent = 0
    00073     );
    00074
    00083     ConnectionManagerInterface(
    00084         const QDBusConnection& connection,
    00085         const QString& busName,
    00086         const QString& objectPath,
    00087         QObject* parent = 0
    00088     );
    00089
    00096     ConnectionManagerInterface(Tp::DBusProxy *proxy);
    00097
    00113     Q_PROPERTY(QStringList Interfaces READ Interfaces)
    00114
    00115
    00123     inline QStringList Interfaces() const TELEPATHY_GNUC_DEPRECATED
    00124     {
    00125         return qvariant_cast<QStringList>(internalPropGet("Interfaces"));
    00126     }
    00127
    00128 public Q_SLOTS:
    00145     inline QDBusPendingReply<Tp::ParamSpecList> GetParameters(const QString& protocol)
    00146     {
    00147         if (!invalidationReason().isEmpty()) {
    00148             return QDBusPendingReply<Tp::ParamSpecList>(QDBusMessage::createError(
    00149                 invalidationReason(),
    00150                 invalidationMessage()
    00151             ));
    00152         }
    00153
    00154
    00155         QList<QVariant> argumentList;
    00156         argumentList << QVariant::fromValue(protocol);
    00157         return asyncCallWithArgumentList(QLatin1String("GetParameters"), argumentList);
    00158     }
    00159
    00170     inline QDBusPendingReply<QStringList> ListProtocols()
    00171     {
    00172         if (!invalidationReason().isEmpty()) {
    00173             return QDBusPendingReply<QStringList>(QDBusMessage::createError(
    00174                 invalidationReason(),
    00175                 invalidationMessage()
    00176             ));
    00177         }
    00178
    00179
    00180         return asyncCall(QLatin1String("ListProtocols"));
    00181     }
    00182
    00283     inline QDBusPendingReply<QString, QDBusObjectPath> RequestConnection(const QString& protocol, const QVariantMap& parameters)
    00284     {
    00285         if (!invalidationReason().isEmpty()) {
    00286             return QDBusPendingReply<QString, QDBusObjectPath>(QDBusMessage::createError(
    00287                 invalidationReason(),
    00288                 invalidationMessage()
    00289             ));
    00290         }
    00291
    00292
    00293         QList<QVariant> argumentList;
    00294         argumentList << QVariant::fromValue(protocol) << QVariant::fromValue(parameters);
    00295         return asyncCallWithArgumentList(QLatin1String("RequestConnection"), argumentList);
    00296     }
    00297
    00298 Q_SIGNALS:
    00316     void NewConnection(const QString& busName, const QDBusObjectPath& objectPath, const QString& protocol);
    00317
    00318 protected:
    00319     virtual void invalidate(Tp::DBusProxy *, const QString &, const QString &);
    00320 };
    00321 }
    00322 }