9#ifndef TOR_LIB_METRICS_METRICS_STORE_ENTRY_H
10#define TOR_LIB_METRICS_METRICS_STORE_ENTRY_H
17#ifdef METRICS_STORE_ENTRY_PRIVATE
21struct metrics_store_entry_t {
47typedef struct metrics_store_entry_t metrics_store_entry_t;
54 const int64_t *buckets);
57#define metrics_store_entry_free(entry) \
58 FREE_AND_NULL(metrics_store_entry_t, metrics_store_entry_free_, (entry));
63 const int64_t bucket);
70 const metrics_store_entry_t *entry);
80 const int64_t value,
const int64_t obs);
Header for lib/metrics/metrics_common.c.
uint64_t metrics_store_hist_entry_get_count(const metrics_store_entry_t *entry)
void metrics_store_entry_update(metrics_store_entry_t *entry, const int64_t value)
bool metrics_store_entry_is_histogram(const metrics_store_entry_t *entry)
uint64_t metrics_store_hist_entry_get_value(const metrics_store_entry_t *entry, const int64_t bucket)
void metrics_store_entry_add_label(metrics_store_entry_t *entry, const char *label)
int64_t metrics_store_hist_entry_get_sum(const metrics_store_entry_t *entry)
metrics_store_entry_t * metrics_store_entry_new(const metrics_type_t type, const char *name, const char *help, size_t bucket_count, const int64_t *buckets)
metrics_store_entry_t * metrics_store_find_entry_with_label(const smartlist_t *entries, const char *label)
void metrics_store_entry_free_(metrics_store_entry_t *entry)
void metrics_store_hist_entry_update(metrics_store_entry_t *entry, const int64_t value, const int64_t obs)
int64_t metrics_store_entry_get_value(const metrics_store_entry_t *entry)
void metrics_store_entry_reset(metrics_store_entry_t *entry)
bool metrics_store_entry_has_label(const metrics_store_entry_t *entry, const char *label)
Integer definitions used throughout Tor.