1/*
2 * BluezQt - Asynchronous BlueZ wrapper library
3 *
4 * SPDX-FileCopyrightText: 2019 Manuel Weichselbaumer <mincequi@web.de>
5 *
6 * SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
7 */
8
9#include "Property.h"
10
11Property::Property()
12{
13}
14
15bool Property::finalize()
16{
17 for (auto tag : m_stringTags) {
18 m_tags.isOptional |= tag.contains(s: QLatin1String("optional"), cs: Qt::CaseInsensitive);
19 m_tags.isExperimental |= tag.contains(s: QLatin1String("experimental"), cs: Qt::CaseInsensitive);
20 m_tags.isReadOnly |= tag.contains(s: QLatin1String("read-only"), cs: Qt::CaseInsensitive);
21 }
22 m_tags.isServerOnly = m_limitation.contains(s: QLatin1String("server only"), cs: Qt::CaseInsensitive);
23
24 bool success = true;
25 success &= m_comment.finalize();
26
27 return success;
28}
29
30QString Property::name() const
31{
32 return m_name;
33}
34
35QString Property::type() const
36{
37 return m_type;
38}
39
40Property::Tags Property::tags() const
41{
42 return m_tags;
43}
44
45QStringList Property::comment() const
46{
47 return m_comment;
48}
49

source code of bluez-qt/tools/bluezapi2qt/Property.cpp