diff options
Diffstat (limited to 'src/bluetooth/qbluetoothdevicediscoveryagent.h')
-rw-r--r-- | src/bluetooth/qbluetoothdevicediscoveryagent.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/bluetooth/qbluetoothdevicediscoveryagent.h b/src/bluetooth/qbluetoothdevicediscoveryagent.h index 954ae704..84087605 100644 --- a/src/bluetooth/qbluetoothdevicediscoveryagent.h +++ b/src/bluetooth/qbluetoothdevicediscoveryagent.h @@ -65,6 +65,7 @@ public: PoweredOffError, InvalidBluetoothAdapterError, UnsupportedPlatformError, + UnsupportedDiscoveryMethod, UnknownError = 100 // New errors must be added before Unknown error }; Q_ENUM(Error) @@ -75,6 +76,15 @@ public: }; Q_ENUM(InquiryType) + enum DiscoveryMethod + { + NoMethod = 0x0, + ClassicMethod = 0x01, + LowEnergyMethod = 0x02, + }; + Q_DECLARE_FLAGS(DiscoveryMethods, DiscoveryMethod) + Q_FLAG(DiscoveryMethods) + explicit QBluetoothDeviceDiscoveryAgent(QObject *parent = Q_NULLPTR); explicit QBluetoothDeviceDiscoveryAgent(const QBluetoothAddress &deviceAdapter, QObject *parent = Q_NULLPTR); @@ -91,8 +101,13 @@ public: QList<QBluetoothDeviceInfo> discoveredDevices() const; + void setLowEnergyDiscoveryTimeout(int msTimeout); + int lowEnergyDiscoveryTimeout() const; + + static DiscoveryMethods supportedDiscoveryMethods(); public Q_SLOTS: void start(); + void start(DiscoveryMethods method); void stop(); Q_SIGNALS: @@ -116,6 +131,8 @@ private: #endif }; +Q_DECLARE_OPERATORS_FOR_FLAGS(QBluetoothDeviceDiscoveryAgent::DiscoveryMethods) + QT_END_NAMESPACE #endif |