|
Open Model Railroad Network (OpenMRN)
|
Base class for implementing update loops. More...
#include <UpdateLoop.hxx>
Public Member Functions | |
| virtual void | notify_update (PacketSource *source, unsigned code)=0 |
| virtual bool | add_refresh_source (PacketSource *source, unsigned priority=0)=0 |
| virtual void | remove_refresh_source (PacketSource *source)=0 |
Static Public Attributes | |
| static constexpr unsigned | EXCLUSIVE_MIN_PRIORITY = 0x100 |
| Priority value for exclusive sources. | |
| static constexpr unsigned | PROGRAMMING_PRIORITY = 0x110 |
| Priority value to be used for service mode programming source. | |
| static constexpr unsigned | ESTOP_PRIORITY = 0x108 |
| Priority value to be used for global emergency stop packet source. | |
Additional Inherited Members | |
Static Public Member Functions inherited from Singleton< UpdateLoopBase > | |
| static UpdateLoopBase * | instance () |
| static bool | exists () |
Base class for implementing update loops.
Usage: make your update loop implementation private-derived from this base class. Create an instance of your class in the main binary.
Note: you may only ever have one live instance of all descendants of this object in a process.
Definition at line 77 of file UpdateLoop.hxx.
|
virtual |
Definition at line 57 of file UpdateLoop.cxx.
|
pure virtual |
Implemented in dcc::SimpleUpdateLoop.
|
pure virtual |
Implemented in dcc::SimpleUpdateLoop.
|
pure virtual |
Implemented in dcc::SimpleUpdateLoop.
|
staticconstexpr |
Priority value to be used for global emergency stop packet source.
Definition at line 91 of file UpdateLoop.hxx.
|
staticconstexpr |
Priority value for exclusive sources.
Definition at line 87 of file UpdateLoop.hxx.
|
staticconstexpr |
Priority value to be used for service mode programming source.
Definition at line 89 of file UpdateLoop.hxx.