Class: QgsSensorAbstractGuiMetadata

Stores GUI metadata about one sensor class.

This is a companion to QgsSensorAbstractMetadata, storing only the components related to the GUI behavior of sensor.

Note

In C++ you can use QgsSensorGuiMetadata convenience class.

Added in version 3.32.

Methods

type

Returns the unique type code for the sensor class.

visibleName

Returns a translated, user visible name identifying the corresponding sensor.

Virtual Methods

In PyQGIS, only methods marked as virtual can be safely overridden in a Python subclass of QgsSensorAbstractGuiMetadata. See the FAQ for more details.

createSensor

Creates an instance of the corresponding sensor type.

createSensorWidget

Creates a configuration widget for an sensor of this type.

creationIcon

Returns an icon representing creation of the sensor type.

class qgis.gui.QgsSensorAbstractGuiMetadata[source]

Bases: object

__init__(type: str | None, visibleName: str | None)

Constructor for QgsSensorAbstractGuiMetadata with the specified class type.

visibleName should be set to a translated, user visible name identifying the corresponding sensor type.

Parameters:
  • type (Optional[str])

  • visibleName (Optional[str])

__init__(a0: QgsSensorAbstractGuiMetadata)
Parameters:

a0 (QgsSensorAbstractGuiMetadata)

virtual createSensor(self, parent: QObject | None) QgsAbstractSensor | None[source]

Creates an instance of the corresponding sensor type.

Parameters:

parent (Optional[QObject])

Return type:

Optional[QgsAbstractSensor]

virtual createSensorWidget(self, sensor: QgsAbstractSensor | None) QgsAbstractSensorWidget | None[source]

Creates a configuration widget for an sensor of this type. Can return None if no configuration GUI is required.

Parameters:

sensor (Optional[QgsAbstractSensor])

Return type:

Optional[QgsAbstractSensorWidget]

virtual creationIcon(self) QIcon[source]

Returns an icon representing creation of the sensor type.

Return type:

QIcon

type(self) str[source]

Returns the unique type code for the sensor class.

Return type:

str

visibleName(self) str[source]

Returns a translated, user visible name identifying the corresponding sensor.

Return type:

str