19 virtual double get()
const = 0;
32 virtual void set(
double number) = 0;
33 virtual double get()
const = 0;
45 typedef std::initializer_list<std::pair<const std::string, std::string>>
Labels;
48 const std::string &name,
const std::string &help_str,
51 const std::string &name,
const std::string &help_str,
Definition metricsbackend.h:12
virtual double get() const =0
virtual void increment(double number=1.0)=0
virtual ~MetricCounter()
Definition metricsbackend.h:16
Definition metricsbackend.h:25
virtual ~MetricGauge()
Definition metricsbackend.h:28
virtual void increment(double number=1.0)=0
virtual void decrement(double number=1.0)=0
virtual double get() const =0
virtual void set(double number)=0
Definition metricsbackend.h:39
std::initializer_list< std::pair< const std::string, std::string > > Labels
Definition metricsbackend.h:45
virtual MetricGaugePtr addGauge(const std::string &name, const std::string &help_str, Labels labels={})
Definition metricsbackend.cpp:80
virtual MetricCounterPtr addCounter(const std::string &name, const std::string &help_str, Labels labels={})
Definition metricsbackend.cpp:74
virtual ~MetricsBackend()
Definition metricsbackend.h:43
std::shared_ptr< MetricCounter > MetricCounterPtr
Definition metricsbackend.h:22
std::shared_ptr< MetricGauge > MetricGaugePtr
Definition metricsbackend.h:36