In questa pagina

QHumiditySensor Class

La classe QHumiditySensor è un wrapper di comodità che avvolge QSensor. Per saperne di più...

Intestazione: #include <QHumiditySensor>
CMake: find_package(Qt6 REQUIRED COMPONENTS Sensors)
target_link_libraries(mytarget PRIVATE Qt6::Sensors)
qmake: QT += sensors
Eredita da: QSensor

Funzioni pubbliche

QHumiditySensor(QObject *parent = nullptr)
virtual ~QHumiditySensor()
QHumidityReading *reading() const

Descrizione dettagliata

L'unica differenza comportamentale consiste nel fatto che questa classe imposta correttamente il tipo.

Questa classe dispone inoltre di una funzione reading() che restituisce un QHumidityReading invece di un QSensorReading.

Per i dettagli sul funzionamento del sensore, consultare QHumidityReading.

Vedere anche QHumidityReading.

Documentazione delle funzioni membro

[explicit] QHumiditySensor::QHumiditySensor(QObject *parent = nullptr)

Crea il sensore come elemento figlio di parent.

[virtual noexcept] QHumiditySensor::~QHumiditySensor()

Distruggi il sensore. Arresta il sensore, se non è già stato arrestato.

QHumidityReading *QHumiditySensor::reading() const

Restituisce la classe di lettura relativa a questo sensore.

Vedi anche QSensor::reading().

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.