Dokit
Internal development documentation
Loading...
Searching...
No Matches
pokitdiscoveryagent_p.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: 2022-2025 Paul Colby <git@colby.id.au>
2// SPDX-License-Identifier: LGPL-3.0-or-later
3
4/*!
5 * \file
6 * Declares the PokitDiscoveryAgentPrivate class.
7 */
8
9#ifndef QTPOKIT_POKITDISCOVERYAGENT_P_H
10#define QTPOKIT_POKITDISCOVERYAGENT_P_H
11
13
14#include <QBluetoothDeviceDiscoveryAgent>
15#include <QBluetoothDeviceInfo>
16#include <QLoggingCategory>
17
19
21
23{
25
26public:
27 static Q_LOGGING_CATEGORY(lc, "pokit.ble.discovery", QtInfoMsg); ///< Logging category.
28
30
31public Q_SLOTS:
32 void canceled() const;
33 void deviceDiscovered(const QBluetoothDeviceInfo &info);
34 #if (QT_VERSION >= QT_VERSION_CHECK(5, 12, 0)) // Required signal, and Fields, added in Qt 5.12.
36 #endif
38 void finished() const;
39
40protected:
41 PokitDiscoveryAgent * q_ptr; ///< Internal q-pointer.
42
43private:
44 Q_DECLARE_PUBLIC(PokitDiscoveryAgent)
47};
48
50
51#endif // QTPOKIT_POKITDISCOVERYAGENT_P_H
void canceled() const
Handle scan canceled signals, by simply logging the event for diagnostic purposes.
PokitDiscoveryAgentPrivate(PokitDiscoveryAgent *const q)
static Q_LOGGING_CATEGORY(lc, "pokit.ble.discovery", QtInfoMsg)
Logging category.
PokitDiscoveryAgent * q_ptr
Internal q-pointer.
void finished() const
Handle scan finished signals, by simply logging the event for diagnostic purposes.
void error(const QBluetoothDeviceDiscoveryAgent::Error error) const
Handle scan errors, by simply logging error for diagnostic purposes.
void deviceDiscovered(const QBluetoothDeviceInfo &info)
Handle deviceDiscovered signals.
void deviceUpdated(const QBluetoothDeviceInfo &info, QBluetoothDeviceInfo::Fields updatedFields)
Handle deviceUpdated signals.
The PokitDiscoveryAgent class discovers nearby Pokit devices.
QObject(QObject *parent)
Q_DISABLE_COPY(Class)
Q_OBJECTQ_OBJECT
Q_SLOTSQ_SLOTS
Global QtPokit library macros.
#define QTPOKIT_BEFRIEND_TEST(Class)
Macro for befriending a related unit test class, but only when QT_TESTLIB_LIB is defined.
#define QTPOKIT_BEGIN_NAMESPACE
Macro for starting the QtPokit library's top-most namespace (if one is defined).
#define QTPOKIT_EXPORT
QtPokit library export/import macro.
#define QTPOKIT_END_NAMESPACE
Macro for ending the QtPokit library's top-most namespace (if one is defined).