diff options
author | Trygve Laugstøl <trygvis@inamo.no> | 2015-02-15 11:01:46 +0100 |
---|---|---|
committer | Trygve Laugstøl <trygvis@inamo.no> | 2015-02-15 11:01:46 +0100 |
commit | 60d5440dd3514e71b87948ff5ed30ee38445b8a5 (patch) | |
tree | 0d983caed47449c875c5188e604e81da29e1b82c /Bluetooth.h | |
parent | 041bbe24b39190ac0b624b2709fc38dea17ad0a7 (diff) | |
download | ble-toys-60d5440dd3514e71b87948ff5ed30ee38445b8a5.tar.gz ble-toys-60d5440dd3514e71b87948ff5ed30ee38445b8a5.tar.bz2 ble-toys-60d5440dd3514e71b87948ff5ed30ee38445b8a5.tar.xz ble-toys-60d5440dd3514e71b87948ff5ed30ee38445b8a5.zip |
o wip. Test cases!
Diffstat (limited to 'Bluetooth.h')
-rw-r--r-- | Bluetooth.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Bluetooth.h b/Bluetooth.h index a0fd2c6..15ef171 100644 --- a/Bluetooth.h +++ b/Bluetooth.h @@ -114,7 +114,7 @@ namespace trygvis { AttPduType getType(); - static vector<AttributeData*>* parseReadByGroupType(ByteBuffer &bytes); + static vector <AttributeData> parseReadByGroupType(ByteBuffer &bytes); static void makeReadByGroupType(ByteBuffer &bytes, uint16_t startHandle, uint16_t endHandle, uint16_t uuid); @@ -126,14 +126,16 @@ namespace trygvis { class AttributeData { public: - static AttributeData* fromByteBuffer(ByteBuffer &value, uint8_t length); + ~AttributeData(); + + static AttributeData fromByteBuffer(ByteBuffer &value, uint8_t length); const uint16_t handle; + const uint16_t groupEndHandle; const ByteBuffer value; private: - AttributeData(uint16_t handle, ByteBuffer value); - ~AttributeData(); + AttributeData(uint16_t handle, uint16_t groupEndHandle, ByteBuffer value); }; // BluetoothAdapter &getAdapter(int hciDevice); |