Obsolete Members for QJSValue

QJSValue 클래스의 다음 멤버들은 더 이상 권장되지 않습니다. 이 멤버들은 기존 소스 코드가 계속 작동하도록 하기 위해 제공됩니다. 새로운 코드에서는 이 멤버들을 사용하지 않는 것을 강력히 권장합니다.

공개 함수

(deprecated in 6.9) bool isVariant() const

멤버 함수 설명

[deprecated in 6.9] bool QJSValue::isVariant() const

이 함수는 6.9 버전부터 사용 중단되었습니다. 새로운 코드에서는 이 함수를 사용하지 않는 것을 강력히 권장합니다.

이 ` QJSValue `가 변형 값(variant value)인 경우 `true`를 반환하고, 그렇지 않은 경우 `false`를 반환합니다.

경고: 이 함수는 예상치 못한 결과를 반환할 가능성이 높습니다. 변형 값은 매우 제한된 경우에만 ` QJSEngine `에 의해 생성됩니다. Qt 5.14 이전 버전에서는 상황이 달랐는데, 당시 ` QJSEngine::toScriptValue `는 해당 ECMAScript 유형 대신 더 많은 유형에 대해 변형 값을 생성했습니다. ` isVariant `가 `false`를 반환하는 많은 값에 대해서는 ` toVariant `를 통해 유효한 ` QVariant `를 얻을 수 있습니다.

toVariant()도 참조하십시오 .

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