QSensorBackendFactory Class
QSensorBackendFactory 类将QSensorBackend 的实例实例化...更多...
头文件: | #include <QSensorBackendFactory> |
CMake: | find_package(Qt6 REQUIRED COMPONENTS Sensors) target_link_libraries(mytarget PRIVATE Qt6::Sensors) |
qmake: | QT += sensors |
公共函数
virtual QSensorBackend * | createBackend(QSensor *sensor) = 0 |
另请参阅 创建传感器插件。
成员函数文档
[pure virtual]
QSensorBackend *QSensorBackendFactory::createBackend(QSensor *sensor)
实例化一个后端。如果工厂处理多个标识符,则应检查sensor ,查看请求的是哪个标识符。
如果工厂无法创建后端,则应返回 0。
© 2025 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.