# Poco::Prometheus

# class GaugeSample

Library: Prometheus
Package: Core
Header: Poco/Prometheus/Gauge.h

## Member Summary

Member Functions: dec, inc, set, setToCurrentTime, timestamp, value

## Constructors

### GaugeSample

GaugeSample() = default;

Creates the GaugeSample.

## Destructor

### ~GaugeSample

~GaugeSample() = default;

Destroys the GaugeSample.

## Member Functions

### dec

void dec(
double v = 1.0
);

Decrements the Gauge's current value.

### inc

void inc(
double v = 1.0
);

Increments the Gauge's current value.

### set

void set(
double v
);

Sets the Gauge's current value.

### set

void set(
Poco::Clock::ClockVal v
);

Sets the Gauge's current value to the given Clock value, converted to seconds.

### setToCurrentTime

void setToCurrentTime();

Sets the Gauge's current value to the current epoch time (seconds since midnight January 1st 1970).

### timestamp

Poco::Timestamp timestamp() const;

Returns the sample's timestamp, which in this implementation is always 0.

### value

double value() const;

Returns the Gauge's current value.