Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qlowenergyserviceprivate.cpp
Go to the documentation of this file.
1
// Copyright (C) 2016 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4
#
include
"qlowenergyserviceprivate_p.h"
5
6
#
include
"qlowenergycontrollerbase_p.h"
7
8
QT_BEGIN_NAMESPACE
9
10
QT_IMPL_METATYPE_EXTERN_TAGGED(QSharedPointer<QLowEnergyServicePrivate>,
11
QSharedPointer_QLowEnergyServicePrivate)
12
13
QLowEnergyServicePrivate::QLowEnergyServicePrivate(QObject *parent) : QObject(parent) { }
14
15
QLowEnergyServicePrivate
::~
QLowEnergyServicePrivate
()
16
{
17
}
18
19
void
QLowEnergyServicePrivate
::
setController
(
QLowEnergyControllerPrivate
*control)
20
{
21
controller = control;
22
23
if
(control)
24
setState(QLowEnergyService::RemoteService);
25
else
26
setState(QLowEnergyService::InvalidService);
27
}
28
29
void
QLowEnergyServicePrivate
::
setError
(QLowEnergyService::ServiceError newError)
30
{
31
lastError = newError;
32
emit errorOccurred(newError);
33
}
34
35
void
QLowEnergyServicePrivate
::
setState
(QLowEnergyService::ServiceState newState)
36
{
37
if
(state == newState)
38
return
;
39
40
state = newState;
41
emit stateChanged(newState);
42
}
43
44
QT_END_NAMESPACE
45
46
#
include
"moc_qlowenergyserviceprivate_p.cpp"
QLowEnergyControllerPrivate
Definition
qlowenergycontrollerbase_p.h:30
QLowEnergyServicePrivate
Definition
qlowenergyserviceprivate_p.h:34
QLowEnergyServicePrivate::~QLowEnergyServicePrivate
~QLowEnergyServicePrivate()
Definition
qlowenergyserviceprivate.cpp:15
QLowEnergyServicePrivate::setController
void setController(QLowEnergyControllerPrivate *control)
Definition
qlowenergyserviceprivate.cpp:19
QLowEnergyServicePrivate::setError
void setError(QLowEnergyService::ServiceError newError)
Definition
qlowenergyserviceprivate.cpp:29
QLowEnergyServicePrivate::setState
void setState(QLowEnergyService::ServiceState newState)
Definition
qlowenergyserviceprivate.cpp:35
QPlatformGraphicsBufferHelper
\inmodule QtGui
qtconnectivity
src
bluetooth
qlowenergyserviceprivate.cpp
Generated on
for Qt by
1.14.0