QBluetooth Namespace
QBluetooth 名前空間は、Bluetooth に関連するクラスや関数を提供します。詳細...
| ヘッダー: | #include <qbluetooth.h> |
| CMake: | find_package(Qt6 REQUIRED COMPONENTS Bluetooth) target_link_libraries(mytarget PRIVATE Qt6::Bluetooth) |
| qmake: | QT += bluetooth |
種類
| enum class | AttAccessConstraint { AttAuthorizationRequired, AttAuthenticationRequired, AttEncryptionRequired } |
| flags | AttAccessConstraints |
| QLowEnergyHandle | |
| enum class | Security { NoSecurity, Authorization, Authentication, Encryption, Secure } |
| flags | SecurityFlags |
型のドキュメント
enum class QBluetooth::AttAccessConstraint
flags QBluetooth::AttAccessConstraints
この列挙型は、ATT属性の読み取りまたは書き込みに必要な要件を記述したものです。
| 定数 | 値 | 説明 |
|---|---|---|
QBluetooth::AttAccessConstraint::AttAuthorizationRequired | 0x1 | クライアントは、属性にアクセスするために ATT サーバーからの認証を必要とします。 |
QBluetooth::AttAccessConstraint::AttAuthenticationRequired | 0x2 | クライアントは、属性にアクセスするために認証を受ける必要があります。 |
QBluetooth::AttAccessConstraint::AttEncryptionRequired | 0x4 | 接続が暗号化されている場合にのみ、この属性にアクセスできます。 |
AttAccessConstraints 型は、QFlags<AttAccessConstraint> の typedef です。これは、AttAccessConstraint 値の OR 組み合わせを格納します。
QLowEnergyHandle
Bluetooth Low EnergyのATT属性ハンドル用のtypedef。
enum class QBluetooth::Security
flags QBluetooth::SecurityFlags
この列挙型は、Bluetooth サービスのセキュリティ要件を記述するものです。
| 定数 | 値 | 説明 |
|---|---|---|
QBluetooth::Security::NoSecurity | 0x00 | このサービスはセキュリティを必要としません。 |
QBluetooth::Security::Authorization | 0x01 | デバイスが「Authorized-Paired」でない限り、このサービスにはユーザーによる認証が必要です。 |
QBluetooth::Security::Authentication | 0x02 | このサービスには認証が必要です。デバイスはペアリングされている必要があり、デバイスが「Authorized-Paired」でない限り、接続時にユーザーに確認のメッセージが表示されます。 |
QBluetooth::Security::Encryption | 0x04 | このサービスでは、通信リンクの暗号化が必要です。これには、デバイスのペアリングが必要です。 |
QBluetooth::Security::Secure | 0x08 | このサービスでは、通信リンクのセキュリティが確保されている必要があります。Bluetooth 2.1 以降の「シンプルペアリング」が必要です。レガシーペアリングは許可されません。 |
SecurityFlags 型は、QFlags<Security> の typedef です。Security 値の論理和(OR)を格納します。
© 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.