Home · Modules · All Classes · All Namespaces
profile-manager.h
1 
23 #ifndef _TelepathyQt_profile_manager_h_HEADER_GUARD_
24 #define _TelepathyQt_profile_manager_h_HEADER_GUARD_
25 
26 #ifndef IN_TP_QT_HEADER
27 #error IN_TP_QT_HEADER
28 #endif
29 
30 #include <TelepathyQt/Object>
31 #include <TelepathyQt/Profile>
32 #include <TelepathyQt/ReadyObject>
33 #include <TelepathyQt/Types>
34 
35 #include <QDBusConnection>
36 #include <QObject>
37 
38 namespace Tp
39 {
40 
41 class PendingOperation;
42 
43 class TP_QT_EXPORT ProfileManager : public Object, public ReadyObject
44 {
45  Q_OBJECT
46  Q_DISABLE_COPY(ProfileManager);
47 
48 public:
49  static const Feature FeatureCore;
51 
52  static ProfileManagerPtr create(const QDBusConnection &bus = QDBusConnection::sessionBus());
53 
54  ~ProfileManager();
55 
56  QList<ProfilePtr> profiles() const;
57  QList<ProfilePtr> profilesForCM(const QString &cmName) const;
58  QList<ProfilePtr> profilesForProtocol(const QString &protocolName) const;
59  ProfilePtr profileForService(const QString &serviceName) const;
60 
61 private Q_SLOTS:
62  TP_QT_NO_EXPORT void onCmNamesRetrieved(Tp::PendingOperation *op);
63  TP_QT_NO_EXPORT void onCMsReady(Tp::PendingOperation *op);
64 
65 private:
66  ProfileManager(const QDBusConnection &bus);
67 
68  struct Private;
69  friend struct Private;
70  Private *mPriv;
71 };
72 
73 } // Tp
74 
75 #endif
static const Feature FeatureFakeProfiles
Definition: profile-manager.h:50
The Feature class represents a feature that can be enabled on demand.
Definition: feature.h:41
Definition: ready-object.h:42
static const Feature FeatureCore
Definition: profile-manager.h:49
The ProfileManager class provides helper methods to retrieve Profile objects.
Definition: profile-manager.h:43
The Object class provides an object with property notification.
Definition: object.h:39
Definition: abstract-adaptor.cpp:31
The PendingOperation class is a base class for pending asynchronous operations.
Definition: pending-operation.h:45