aboutsummaryrefslogtreecommitdiff
path: root/src/feature/stats/connstats.h
blob: 2abe8d7362663fde5877e95a808434f519995863 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/* Copyright (c) 2001 Matej Pfajfar.
 * Copyright (c) 2001-2004, Roger Dingledine.
 * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
 * Copyright (c) 2007-2020, The Tor Project, Inc. */
/* See LICENSE for licensing information */

/**
 * @file connstats.h
 * @brief Header for feature/stats/connstats.c
 **/

#ifndef TOR_FEATURE_STATS_CONNSTATS_H
#define TOR_FEATURE_STATS_CONNSTATS_H

void rep_hist_conn_stats_init(time_t now);
void rep_hist_note_or_conn_bytes(uint64_t conn_id, size_t num_read,
                                 size_t num_written, time_t when);
void rep_hist_reset_conn_stats(time_t now);
char *rep_hist_format_conn_stats(time_t now);
time_t rep_hist_conn_stats_write(time_t now);
void rep_hist_conn_stats_term(void);
void bidi_map_free_all(void);

#endif /* !defined(TOR_FEATURE_STATS_CONNSTATS_H) */