A class which manage global events firing and events QoS. More...
#include <eventBus.hpp>
Public Member Functions | |
| bool | addObserver (anch::events::Observer< T > &observer) noexcept |
| void | removeObserver (anch::events::Observer< T > &observer) noexcept |
| void | fireEvent (const T &event, const std::map< std::string, std::string > &headers={}) noexcept |
| void | fireEvent (const anch::events::Event< T > &event) noexcept |
| void | scheduleDeferred (const T &event, const std::map< std::string, std::string > &headers={}) noexcept |
| void | scheduleDeferred (const anch::events::Event< T > &event) noexcept |
Static Public Member Functions | |
| static bool | AddObserver (anch::events::Observer< T > &observer) noexcept |
| static void | RemoveObserver (anch::events::Observer< T > &observer) noexcept |
| static void | FireEvent (const T &event, const std::map< std::string, std::string > &headers={}) noexcept |
| static void | FireEvent (const anch::events::Event< T > &event) noexcept |
| static void | ScheduleDeferred (const T &event, const std::map< std::string, std::string > &headers={}) noexcept |
| static void | ScheduleDeferred (const anch::events::Event< T > &event) noexcept |
| Static Public Member Functions inherited from anch::Singleton< EventBus< T > > | |
| static T & | getInstance () |
Friends | |
| class | anch::Singleton< EventBus< T > > |
A class which manage global events firing and events QoS.
EventBus is a singleton.
|
staticnoexcept |
|
noexcept |
|
staticnoexcept |
Retrieve EventBus instance and notify all observer that an event has been fired
| event | the event which has been fired |
|
staticnoexcept |
Retrieve EventBus instance and notify all observer that an event has been fired
| event | the event which has been fired |
| headers | the event's context |
|
noexcept |
Notify all observer that an event has been fired
| event | the event which has been fired |
|
noexcept |
Notify all observer that an event has been fired
| event | the event which has been fired |
| headers | the event's context |
|
staticnoexcept |
Retrieve EventBus instance and remove observer for notifications
| observer | The observer to remove |
|
noexcept |
Remove observer for notifications
| observer | The observer to remove |
|
staticnoexcept |
Retrieve EventBus instance and put event in sheduler.
| event | the event to process |
|
staticnoexcept |
Retrieve EventBus instance and put event in sheduler.
| event | the event to process |
| headers | the event's context |
|
noexcept |
Put event in sheduler.
| event | the event to process |
|
noexcept |
Put event in sheduler.
| event | the event to process |
| headers | the event's context |