MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ is_device_open()

bool MayaFlux::Core::SerialInputBackend::is_device_open ( uint32_t device_id) const
nodiscardoverridevirtual

Check if a device is currently open.

Implements MayaFlux::Core::IInputBackend.

Definition at line 369 of file SerialInputBackend.cpp.

370{
371 if (const auto roster = m_roster.read()) {
372 const auto it = roster->entries.find(device_id);
373 if (it != roster->entries.end() && it->second.parent != 0) {
374 return it->second.view_reader != 0 && get_device(it->second.parent) != nullptr;
375 }
376 }
377 return get_device(device_id) != nullptr;
378}
std::shared_ptr< SerialDevice > get_device(uint32_t device_id) const
The open device, or null.
Memory::SnapshotCell< Roster > m_roster

References get_device(), is_device_open(), and m_roster.

Referenced by is_device_open().

Here is the call graph for this function:
Here is the caller graph for this function: