diff options
author | Sven Gothel <[email protected]> | 2020-12-10 05:20:25 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2020-12-10 05:20:25 +0100 |
commit | 29119b366a14f27ec21f225924b1f8ef4b8a65e7 (patch) | |
tree | f17bd366742c9155be9fed02d83d227e15841fad /src | |
parent | bd4b5f0a3af7d172894b9fdd26d37aa08901f3b1 (diff) |
Java API: Add and use a 'native' EUI48 (6 bytes, new class) and BluetoothAddressType instead of String (17+1 bytes)
Direct-BT natively uses EUI48 (uint8_t[6]) and it is desired to utilize same 'native' semantic type
in Java land, avoiding resource and generic string-type abuse.
This impacts the interface BluetoothAdapter and BluetoothDevice, as well their implementations.
- Direct-BT uses the native EUI48 byte array
- DBus sticks with the dbus string representation, when interfacing native land for dbus.
Diffstat (limited to 'src')
-rw-r--r-- | src/direct_bt/BTTypes.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/direct_bt/BTTypes.cpp b/src/direct_bt/BTTypes.cpp index f588e3b0..f1553941 100644 --- a/src/direct_bt/BTTypes.cpp +++ b/src/direct_bt/BTTypes.cpp @@ -169,7 +169,7 @@ EUI48::EUI48(const std::string str) { if ( sscanf(str.c_str(), "%02hhx:%02hhx:%02hhx:%02hhx:%02hhx:%02hhx", &b[5], &b[4], &b[3], &b[2], &b[1], &b[0]) != 6 ) { - std::string msg("EUI48 string not in format '00:00:00:00:00:00' but "+str); + std::string msg("EUI48 string not in format '01:02:03:0A:0B:0C' but "+str); throw jau::IllegalArgumentException(msg, E_FILE_LINE); } |