| 1 |
/* |
| 2 |
* BluezQt - Asynchronous Bluez wrapper library |
| 3 |
* |
| 4 |
* SPDX-FileCopyrightText: 2022 Pontus Sjögren |
| 5 |
* |
| 6 |
* SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL |
| 7 |
*/ |
| 8 |
|
| 9 |
#include "gattdescriptor_p.h" |
| 10 |
#include "gattcharacteristic.h" |
| 11 |
|
| 12 |
namespace BluezQt |
| 13 |
{ |
| 14 |
|
| 15 |
GattDescriptorPrivate::GattDescriptorPrivate(const QString &uuid, |
| 16 |
const QStringList &flags, |
| 17 |
const QByteArray &initialValue, |
| 18 |
const GattCharacteristic *characteristic) |
| 19 |
: m_uuid(uuid) |
| 20 |
, m_characteristic(characteristic) |
| 21 |
, m_value(initialValue) |
| 22 |
, m_flags(flags) |
| 23 |
{ |
| 24 |
static std::uint8_t descNumber = 0; |
| 25 |
m_objectPath.setPath(m_characteristic->objectPath().path() + QStringLiteral("/desc") + QString::number(descNumber++)); |
| 26 |
} |
| 27 |
|
| 28 |
} |