Merge branch 'master' into contact_dialog
[situare] / src / engine / contactmanager.h
1 #ifndef CONTACTMANAGER_H
2 #define CONTACTMANAGER_H
3
4 #include <QObject>
5 #include <QHash>
6
7 class ContactManagerPrivate;
8
9 class ContactManager : public QObject
10 {
11     Q_OBJECT
12 public:
13     /**
14     * @brief Friend class for ContactManagerPrivate.
15     */
16     friend class ContactManagerPrivate;
17
18     ContactManager(QObject *parent = 0);
19
20 /*******************************************************************************
21 * MEMBER FUNCTIONS AND SLOTS
22 ******************************************************************************/
23     /**
24     * @brief Returns contact's guid from contact's facebook ID.
25     *
26     * @param facebookId contact's facebook ID
27     * @return contact guid
28     */
29     QString contactGuid(const QString &facebookId) const;
30
31     /**
32     * @brief Requests contact guids.
33     *
34     * Guid is a globally unique ID of a contact, which can be used with
35     * other datastores.
36     */
37     void requestContactGuids();
38
39 /*******************************************************************************
40 * SIGNALS
41 ******************************************************************************/
42 signals:
43     /**
44     * @brief Signal for contacts guids added.
45     *
46     * Contact guids has Facebook ID as key and Guid as value.. Guid is a globally
47     * unique ID of a contact, which can be used with other datastores.
48     * @param contactGuids list of contact guids
49     */
50     void contactsGuidsAdded(const QHash<QString, QString> &contactGuids);
51
52 /******************************************************************************
53 * DATA MEMBERS
54 ******************************************************************************/
55 private:
56     ContactManagerPrivate *m_contactManagerPrivate; ///< ContactManagerPrivate
57 };
58
59 #endif // CONTACTMANAGER_H