QBluetoothAddress Class

QBluetoothAddress クラスは Bluetooth デバイスにアドレスを割り当てます。詳細...

Header: #include <QBluetoothAddress>
qmake: QT += bluetooth

パブリック関数

QBluetoothAddress()
QBluetoothAddress(const QString &address)
QBluetoothAddress(quint64 address)
void clear()
bool isNull() const
QString toString() const
quint64 toUInt64() const
(since 6.6) size_t qHash(const QBluetoothAddress &key, size_t seed = 0)
bool operator!=(const QBluetoothAddress &a, const QBluetoothAddress &b)
bool operator<(const QBluetoothAddress &a, const QBluetoothAddress &b)
bool operator==(const QBluetoothAddress &a, const QBluetoothAddress &b)

詳細説明

このクラスは、プラットフォームやプロトコルに依存しない方法で Bluetooth アドレスを保持します。

メンバ関数ドキュメント

[constexpr noexcept] QBluetoothAddress::QBluetoothAddress()

null の Bluetooth Address を構築します。

[explicit] QBluetoothAddress::QBluetoothAddress(const QString &address)

新しい Bluetooth アドレスを構築し、address を割り当てます。

address のフォーマットは、XX:XX:XX:XX:XX:XX または XXXXXXXXXXXXXX(Xは16進数)のいずれかです。大文字小文字は重要ではない。

[explicit constexpr noexcept] QBluetoothAddress::QBluetoothAddress(quint64 address)

新しいBluetoothアドレスを構築し、address

[noexcept] void QBluetoothAddress::clear()

Bluetoothアドレスを00:00:00:00:00:00に設定します。

[noexcept] bool QBluetoothAddress::isNull() const

BluetoothアドレスがNULLの場合はtrueを返し、そうでない場合はfalseを返します。

QString QBluetoothAddress::toString() const

BluetoothのアドレスをXX:XX:XX:XX:XX:XXという形式の文字列で返します。

[noexcept] quint64 QBluetoothAddress::toUInt64() const

このBluetoothアドレスをquint64で返します。

関連する非会員

[noexcept, since 6.6] size_t qHash(const QBluetoothAddress &key, size_t seed = 0)

key のハッシュ値を返します。計算のシードとしてseed を使用します。

この関数は Qt 6.6 で導入されました。

bool operator!=(const QBluetoothAddress &a, const QBluetoothAddress &b)

2つのBluetoothアドレスab が等しくなければtrue を返し、そうでなければfalse を返す。

bool operator<(const QBluetoothAddress &a, const QBluetoothAddress &b)

Bluetooth アドレスab よりも小さい場合は true を返し、そうでない場合は false を返します。

bool operator==(const QBluetoothAddress &a, const QBluetoothAddress &b)

2つのBluetoothアドレスab が等しい場合はtrue を返し、そうでない場合はfalse を返す。

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