OpenCPN Partial API docs
|
The global driver registry, a singleton. More...
#include <comm_drv_registry.h>
Public Member Functions | |
void | Activate (DriverPtr driver) |
Add driver to list of active drivers. | |
void | Deactivate (DriverPtr &driver) |
Remove driver from list of active drivers. | |
void | CloseAllDrivers () |
Close and destroy all drivers completely. | |
const std::vector< DriverPtr > & | GetDrivers () const |
Static Public Member Functions | |
static CommDriverRegistry & | GetInstance () |
Public Attributes | |
EventVar | evt_driverlist_change |
Notified by all driverlist updates. | |
EventVar | evt_dump_stats |
Notified when receiving –remote –dump_stat on local API. | |
EventVar | evt_comm_overrun |
Notified with a printable message on first detected overrun. | |
EventVar | evt_driver_stats |
Regularly notified by drivers with a DriverStats shared_ptr. | |
EventVar | evt_driver_msg |
Notified for messages from drivers. | |
The global driver registry, a singleton.
Drivers register here when activated, transport layer finds them.
Also used as exchange point for messages for USB devices hotplug events.
Definition at line 40 of file comm_drv_registry.h.
void CommDriverRegistry::Activate | ( | DriverPtr | driver | ) |
Add driver to list of active drivers.
Definition at line 32 of file comm_drv_registry.cpp.
void CommDriverRegistry::CloseAllDrivers | ( | ) |
Close and destroy all drivers completely.
Definition at line 53 of file comm_drv_registry.cpp.
void CommDriverRegistry::Deactivate | ( | DriverPtr & | driver | ) |
Remove driver from list of active drivers.
Definition at line 42 of file comm_drv_registry.cpp.
const std::vector< DriverPtr > & CommDriverRegistry::GetDrivers | ( | ) | const |
Definition at line 49 of file comm_drv_registry.cpp.
|
static |
Definition at line 59 of file comm_drv_registry.cpp.
EventVar CommDriverRegistry::evt_comm_overrun |
Notified with a printable message on first detected overrun.
Definition at line 63 of file comm_drv_registry.h.
EventVar CommDriverRegistry::evt_driver_msg |
Notified for messages from drivers.
The generated event contains:
Definition at line 74 of file comm_drv_registry.h.
EventVar CommDriverRegistry::evt_driver_stats |
Regularly notified by drivers with a DriverStats shared_ptr.
Definition at line 66 of file comm_drv_registry.h.
EventVar CommDriverRegistry::evt_driverlist_change |
Notified by all driverlist updates.
Definition at line 57 of file comm_drv_registry.h.
EventVar CommDriverRegistry::evt_dump_stats |
Notified when receiving –remote –dump_stat on local API.
Definition at line 60 of file comm_drv_registry.h.