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

base-debug.h
1
22 #ifndef _TelepathyQt_base_debug_h_HEADER_GUARD_
23 #define _TelepathyQt_base_debug_h_HEADER_GUARD_
24
25 #ifndef IN_TP_QT_HEADER
26 #error IN_TP_QT_HEADER
27 #endif
28
29 #include <TelepathyQt/Callbacks>
30 #include <TelepathyQt/Constants>
31 #include <TelepathyQt/DBusService>
32 #include <TelepathyQt/Global>
33 #include <TelepathyQt/Types>
34
35 namespace Tp
36 {
37
38 class TP_QT_EXPORT BaseDebug : public DBusService
39 {
40 Q_OBJECT
41 public:
42 explicit BaseDebug(const QDBusConnection &dbusConnection = QDBusConnection::sessionBus());
43
44 bool isEnabled() const;
45 int getMessagesLimit() const;
46
47 typedef Callback1<DebugMessageList, DBusError*> GetMessagesCallback;
48 void setGetMessagesCallback(const GetMessagesCallback &cb);
49
50 DebugMessageList getMessages(DBusError *error) const;
51
52 public Q_SLOTS:
53 void setEnabled(bool enabled);
54 void setGetMessagesLimit(int limit);
55 void clear();
56
57 void newDebugMessage(const QString &domain, DebugLevel level, const QString &message);
58 void newDebugMessage(double time, const QString &domain, DebugLevel level, const QString &message);
59
60 QVariantMap immutableProperties() const;
61
62 bool registerObject(DBusError *error = NULL);
63
64 protected:
65 class Adaptee;
66 friend class Adaptee;
67 struct Private;
68 friend struct Private;
69 Private *mPriv;
70 };
71
72 } // namespace Tp
73
74 #endif // _TelepathyQt_base_debug_h_HEADER_GUARD_
QDBusConnection
QDBusConnection::sessionBus
QDBusConnection sessionBus()
Tp::DebugLevel
DebugLevel
Definition: obj-x86_64-linux-gnu/TelepathyQt/_gen/constants.h:4036
Tp::DBusService
Base class for D-Bus services.
Definition: dbus-service.h:46
Tp::DBusError
Small container class, containing a D-Bus error.
Definition: dbus-error.h:35
QString
QList
Tp::Callback1< DebugMessageList, DBusError * >
Tp::BaseDebug::GetMessagesCallback
Callback1< DebugMessageList, DBusError * > GetMessagesCallback
Definition: base-debug.h:47
Tp::BaseDebug
Definition: base-debug.h:38
Tp
Definition: abstract-adaptor.cpp:31
Tp::BaseDebug::mPriv
Private * mPriv
Definition: base-debug.h:69