3 #include <Poco/Event.h>
4 #include <Poco/Mutex.h>
5 #include <Poco/Timespan.h>
7 #include "core/DeviceManager.h"
8 #include "hotplug/HotplugListener.h"
17 const std::initializer_list<std::type_index> &acceptable = {});
94 std::string
dongleName(
bool failWhenMissing =
true)
const;
101 Poco::Event &
event();
104 mutable Poco::FastMutex m_lock;
106 std::string m_dongleName;
107 unsigned int m_attemptsCount;
108 Poco::Timespan m_retryTimeout;
Definition: FailDetector.h:8
Definition: HotplugListener.h:9
void setAttemptsCount(const int count)
Definition: DongleDeviceManager.cpp:20
virtual void dongleAvailable()=0
virtual void dongleFailed(const FailDetector &dongleStatus)
Definition: DongleDeviceManager.cpp:41
Poco::Event & event()
Definition: DongleDeviceManager.cpp:70
virtual void notifyDongleRemoved()
The default implementation does nothing.
Definition: DongleDeviceManager.cpp:56
std::string dongleName(bool failWhenMissing=true) const
Definition: DongleDeviceManager.cpp:60
Definition: DeviceManager.h:48
Definition: HotplugEvent.h:10
Definition: DongleDeviceManager.h:14
virtual bool dongleMissing()
Definition: DongleDeviceManager.cpp:36
void stop() override
Definition: DongleDeviceManager.cpp:176
virtual std::string dongleMatch(const HotplugEvent &e)=0
void setRetryTimeout(const Poco::Timespan &timeout)
Definition: DongleDeviceManager.cpp:28
DevicePrefix prefix() const override
Definition: DeviceManager.cpp:33