sensorfw
sensormanager_i.h
Go to the documentation of this file.
1
30#ifndef SENSORMANAGER_I_H
31#define SENSORMANAGER_I_H
32
33#include <QtDBus/QtDBus>
34#include <QString>
35#include "sfwerror.h"
36
40class LocalSensorManagerInterface : public QDBusAbstractInterface
41{
42 Q_OBJECT
43 Q_DISABLE_COPY(LocalSensorManagerInterface)
45 Q_PROPERTY(QString errorString READ errorString)
46 Q_PROPERTY(int errorCodeInt READ errorCodeInt NOTIFY errorSignal)
47
53 int errorCodeInt();
54
55public:
61 static const char* staticInterfaceName;
62
67
74
80 QString errorString();
81
82public Q_SLOTS:
83
90 QDBusReply<bool> loadPlugin(const QString& name);
91
98 QDBusReply<int> requestSensor(const QString& id);
99
107 QDBusReply<bool> releaseSensor(const QString& id, int sessionId);
108
109Q_SIGNALS:
110
116 void errorSignal(int error);
117
121
122protected:
123
132 LocalSensorManagerInterface(const QString& service, const QString& path, const QDBusConnection& connection, QObject* parent = 0);
133
134protected slots:
135 void loadPluginFinished(QDBusPendingCallWatcher *watch);
136 void requestSensorFinished(QDBusPendingCallWatcher *watch);
137 void releaseSensorFinished(QDBusPendingCallWatcher *watch);
138
139};
140
141namespace local {
143}
144#endif
DBus interface to SensorManager instance.
QDBusReply< bool > loadPlugin(const QString &name)
Request sensor daemon to load plugin.
QDBusReply< int > requestSensor(const QString &id)
Request sensor deamon to start new session for sensor.
static const char * staticInterfaceName
Get name of the D-Bus interface for this class.
void errorSignal(int error)
Signal about occured errors.
SensorManagerError errorCode
QDBusReply< bool > releaseSensor(const QString &id, int sessionId)
Request sensor deamon to release existing session.
Error definitions.
SensorManagerError
Enumeration about SensorManager error states.
Definition sfwerror.h:38