|
| ~memh () noexcept |
| Destructor that cleans up all event resolvers.
|
template<typename _Func> |
void | route (_RawEvent &event, _Func const &onError) const |
| Routes an event to the appropriate handlers with error handling.
|
template<typename _Event> |
void | subscribe (_Handler &handler) |
| Subscribe a handler to events of a specific type.
|
template<typename _Event> |
void | unsubscribe (_Handler &handler) const |
| Unsubscribe a handler from events of a specific type.
|
void | unsubscribe (_Handler const &handler) const |
| Unsubscribe a handler from all event types.
|
void | unsubscribe (_HandlerId const &id) const |
| Unsubscribe a handler by ID from all event types.
|
template<typename _RawEvent, bool _CleanEvent = true, typename _Handler = void>
class qb::router::memh< _RawEvent, _CleanEvent, _Handler >
Multiple-Event Multiple-Handler router (generic version)
Routes multiple event types to multiple handlers based on event type and handler IDs.
- Template Parameters
-
_RawEvent | The raw event base type |
_CleanEvent | Whether to clean up events after routing |
_Handler | The handler type (void for heterogeneous handlers) |