16#ifndef QGSSENSORGUIREGISTRY_H
17#define QGSSENSORGUIREGISTRY_H
56 QString
type()
const {
return mType; }
103 QString mVisibleName;
263 QMap<QString, QgsSensorAbstractGuiMetadata *> mMetadata;
An abstract base class for sensors.
static QIcon getThemeIcon(const QString &name, const QColor &fillColor=QColor(), const QColor &strokeColor=QColor())
Helper to get a theme icon.
QgsSensorGuiRegistry(QObject *parent=nullptr)
Creates a new empty sensor GUI registry.
QgsSensorGuiRegistry(const QgsSensorGuiRegistry &rh)=delete
QgsSensorAbstractGuiMetadata * sensorMetadata(const QString &type) const
Returns the metadata for the specified sensor type.
QgsAbstractSensor * createSensor(const QString &type, QObject *parent=nullptr) const
Creates a new instance of a sensor given the type.
bool populate()
Populates the registry with standard sensor types.
void sensorAdded(const QString &type, const QString &name)
Emitted whenever a new sensor type is added to the registry, with the specified type.
QMap< QString, QString > sensorTypes() const
Returns a list of sensor types handled by the registry.
QgsAbstractSensorWidget * createSensorWidget(QgsAbstractSensor *sensor) const
Creates a new instance of a sensor configuration widget for the specified sensor.
QgsSensorGuiRegistry & operator=(const QgsSensorGuiRegistry &rh)=delete
bool addSensorGuiMetadata(QgsSensorAbstractGuiMetadata *metadata)
Registers the GUI metadata for a new sensor type.
std::function< QgsAbstractSensorWidget *(QgsAbstractSensor *sensor)> QgsSensorWidgetFunc
Sensor configuration widget creation function.
std::function< QgsAbstractSensor *(QObject *parent)> QgsSensorCreateFunc
Sensor creation function.