C++ Actor Framework  0.18
Public Types | Public Member Functions | Static Public Attributes | List of all members
caf::telemetry::int_gauge Class Reference

A metric that represents a single integer value that can arbitrarily go up and down. More...

#include <int_gauge.hpp>

Collaboration diagram for caf::telemetry::int_gauge:
Collaboration graph

Public Types

using value_type = int64_t
 
using family_setting = unit_t
 

Public Member Functions

 int_gauge (int64_t value) noexcept
 
 int_gauge (span< const label >) noexcept
 
void inc () noexcept
 Increments the gauge by 1.
 
void inc (int64_t amount) noexcept
 Increments the gauge by amount.
 
void dec () noexcept
 Decrements the gauge by 1.
 
void dec (int64_t amount) noexcept
 Decrements the gauge by amount.
 
void value (int64_t x) noexcept
 Sets the gauge to x.
 
int64_t operator++ () noexcept
 Increments the gauge by 1. More...
 
int64_t operator-- () noexcept
 Decrements the gauge by 1. More...
 
int64_t value () const noexcept
 Returns the current value of the gauge.
 

Static Public Attributes

static constexpr metric_type runtime_type = metric_type::int_gauge
 

Detailed Description

A metric that represents a single integer value that can arbitrarily go up and down.

Member Function Documentation

◆ operator++()

int64_t caf::telemetry::int_gauge::operator++ ( )
noexcept

Increments the gauge by 1.

Returns
The new value of the gauge.

◆ operator--()

int64_t caf::telemetry::int_gauge::operator-- ( )
noexcept

Decrements the gauge by 1.

Returns
The new value of the gauge.

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