* @brief Selects the discovered service whose UUID matches, by delegating to selectService. */
| 1025 | * @brief Selects the discovered service whose UUID matches, by delegating to selectService. |
| 1026 | */ |
| 1027 | bool IO::Drivers::BluetoothLE::selectServiceByUuid(const QString& uuid) |
| 1028 | { |
| 1029 | const QBluetoothUuid target = bleUuidFromString(uuid); |
| 1030 | if (target.isNull()) |
| 1031 | return false; |
| 1032 | |
| 1033 | for (int i = 0; i < m_serviceUuids.count(); ++i) { |
| 1034 | if (QBluetoothUuid(m_serviceUuids.at(i)) == target) { |
| 1035 | selectService(i + 1); |
| 1036 | return true; |
| 1037 | } |
| 1038 | } |
| 1039 | |
| 1040 | return false; |
| 1041 | } |
| 1042 | |
| 1043 | /** |
| 1044 | * @brief Subscribes to the notify characteristic with the given UUID, by index delegation. |
nothing calls this directly
no test coverage detected