이 페이지에서

QmlSensors QML Type

QmlSensors 싱글톤은 모듈 API를 제공합니다. 더 보기...

Import Statement: import QtSensors
Since: QtSensors 5.0

메서드

상세 설명

QmlSensors 싱글톤은 모듈 API를 제공합니다.

이 요소는 직접 생성할 수 없지만, 아래 예시와 같이 QML 싱글톤으로서 그 기능에 접근할 수 있습니다:

import QtSensors
import QtSensors as Sensors
...
    Component.onCompleted: {
        var types = Sensors.QmlSensors.sensorTypes();
        console.log(types.join(", "));
    }

메서드 문서

string defaultSensorForType(type)

type 에 등록된 기본 센서 식별자를 반환합니다.

자세한 내용은 QSensor::defaultSensorForType()을 참조하십시오.

list<string> sensorTypes()

등록된 센서 유형의 목록을 반환합니다.

자세한 내용은 QSensor::sensorTypes()을 참조하십시오.

list<string> sensorsForType(type)

type 에 등록된 센서 식별자 목록을 반환합니다.

자세한 내용은 QSensor::sensorsForType()을 참조하십시오.

© 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.