Common System 0.2.0
Common interfaces and patterns for system integration
Loading...
Searching...
No Matches
kcenon::common::events::metric_event Struct Reference

Event for publishing metrics. More...

#include <event_bus.h>

Collaboration diagram for kcenon::common::events::metric_event:
Collaboration graph

Public Member Functions

 metric_event (const std::string &n, double v, const std::string &u="")
 

Public Attributes

std::string name
 
double value
 
std::string unit
 
std::chrono::steady_clock::time_point timestamp
 

Detailed Description

Event for publishing metrics.

Definition at line 547 of file event_bus.h.

Constructor & Destructor Documentation

◆ metric_event()

kcenon::common::events::metric_event::metric_event ( const std::string & n,
double v,
const std::string & u = "" )
inline

Definition at line 553 of file event_bus.h.

554 : name(n), value(v), unit(u),
555 timestamp(std::chrono::steady_clock::now()) {}
std::chrono::steady_clock::time_point timestamp
Definition event_bus.h:551

Member Data Documentation

◆ name

std::string kcenon::common::events::metric_event::name

Definition at line 548 of file event_bus.h.

◆ timestamp

std::chrono::steady_clock::time_point kcenon::common::events::metric_event::timestamp

Definition at line 551 of file event_bus.h.

◆ unit

std::string kcenon::common::events::metric_event::unit

Definition at line 550 of file event_bus.h.

◆ value

double kcenon::common::events::metric_event::value

Definition at line 549 of file event_bus.h.


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