| 132 | } |
| 133 | |
| 134 | bool hasDevice(Device::Type type) { |
| 135 | auto scoped_mutex = mutex.asScopedLock(); |
| 136 | scoped_mutex.lock(); |
| 137 | auto result_set = getDevices() | std::views::filter([&type](auto& device) { |
| 138 | return device->getType() == type; |
| 139 | }); |
| 140 | return !result_set.empty(); |
| 141 | } |
| 142 | |
| 143 | } |
no test coverage detected