Monitoring System 0.1.0
System resource monitoring with pluggable collectors and alerting
Loading...
Searching...
No Matches
kcenon::monitoring::interface_event_publisher Class Referenceabstract

Interface for components that publish events. More...

#include <event_bus_interface.h>

Collaboration diagram for kcenon::monitoring::interface_event_publisher:
Collaboration graph

Public Member Functions

virtual ~interface_event_publisher ()=default
 
virtual common::VoidResult set_event_bus (std::shared_ptr< interface_event_bus > bus)=0
 Set the event bus for publishing.
 
virtual std::shared_ptr< interface_event_busget_event_bus () const =0
 Get the current event bus.
 

Detailed Description

Interface for components that publish events.

Components implementing this interface can publish events to an event bus. This provides a standardized way to decouple event producers from consumers.

Thread Safety:
Implementations should ensure thread-safe access to the event bus reference.

Definition at line 419 of file event_bus_interface.h.

Constructor & Destructor Documentation

◆ ~interface_event_publisher()

virtual kcenon::monitoring::interface_event_publisher::~interface_event_publisher ( )
virtualdefault

Member Function Documentation

◆ get_event_bus()

virtual std::shared_ptr< interface_event_bus > kcenon::monitoring::interface_event_publisher::get_event_bus ( ) const
pure virtual

Get the current event bus.

Returns
Shared pointer to the event bus
Examples
/home/runner/work/monitoring_system/monitoring_system/include/kcenon/monitoring/interfaces/event_bus_interface.h.

◆ set_event_bus()

virtual common::VoidResult kcenon::monitoring::interface_event_publisher::set_event_bus ( std::shared_ptr< interface_event_bus > bus)
pure virtual

Set the event bus for publishing.

Parameters
busThe event bus to use
Returns
Result indicating success or failure
Examples
/home/runner/work/monitoring_system/monitoring_system/include/kcenon/monitoring/interfaces/event_bus_interface.h.

The documentation for this class was generated from the following file: