tor  0.4.2.0-alpha-dev
netstatus.h
1 /* Copyright (c) 2001 Matej Pfajfar.
2  * Copyright (c) 2001-2004, Roger Dingledine.
3  * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
4  * Copyright (c) 2007-2019, The Tor Project, Inc. */
5 /* See LICENSE for licensing information */
6 
7 #ifndef TOR_NETSTATUS_H
8 #define TOR_NETSTATUS_H
9 
10 int net_is_disabled(void);
11 int net_is_completely_disabled(void);
12 
13 void note_user_activity(time_t now);
14 void reset_user_activity(time_t now);
15 time_t get_last_user_activity_time(void);
16 
17 void set_network_participation(bool participation);
18 bool is_participating_on_network(void);
19 
20 void netstatus_flush_to_state(or_state_t *state, time_t now);
21 void netstatus_load_from_state(const or_state_t *state, time_t now);
22 void netstatus_note_clock_jumped(time_t seconds_diff);
23 
24 #endif /* !defined(TOR_NETSTATUS_H) */