86f179d431f466209588a46a4f418d5cf86b07d3
[profile/ivi/bluetooth-qt.git] / asyncagent.h
1 /*  -*- Mode: C++ -*-
2  *
3  * meego handset bluetooth
4  * Copyright © 2010, Intel Corporation.
5  *
6  * This program is licensed under the terms and conditions of the
7  * Apache License, version 2.0.  The full text of the Apache License is at
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  */
11
12 #ifndef ASYNCAGENT_H
13 #define ASYNCAGENT_H
14
15 #include "bluetoothbaseagent.h"
16
17 class AsyncAgent : public BluetoothBaseAgent
18 {
19     Q_OBJECT
20 public:
21         explicit AsyncAgent(QString path, QObject *parent = 0);
22
23         void requestConfirmation(OrgBluezDeviceInterface &device, uint key);
24         uint requestPasskey(OrgBluezDeviceInterface &device);
25         QString requestPidCode(OrgBluezDeviceInterface &device);
26
27 signals:
28
29 public slots:
30         void replyRequestConfirmation(bool confirmed);
31         void replyPasskey(uint passkey);
32         void replyRequestPidCode(QString pidCode);
33
34 private:
35         QDBusMessage pendingMessage;
36         QDBusConnection m_connection;
37
38 };
39
40 #endif // ASYNCAGENT_H