vnstat  2.9
About: vnStat is a console-based network traffic monitor (using the /proc filesystem).
  Fossies Dox: vnstat-2.9.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

Go to the documentation of this file.
1#ifndef DATACACHE_H
2#define DATACACHE_H
4typedef struct datacache {
5 char interface[32];
6 short active;
7 short filled;
8 short syncneeded;
9 uint64_t currx, curtx;
10 time_t updated;
11 struct xferlog *log;
12 struct datacache *next;
15typedef struct xferlog {
16 time_t timestamp;
17 uint64_t rx, tx;
18 struct xferlog *next;
21int datacache_add(datacache **dc, const char *interface, const short sync);
22int datacache_remove(datacache **dc, const char *interface);
23void datacache_clear(datacache **dc);
26void datacache_debug(datacache **dc);
28int xferlog_add(xferlog **log, const time_t timestamp, const uint64_t rx, const uint64_t tx);
29void xferlog_clear(xferlog **log);
30void xferlog_debug(xferlog **log, const int newline);
int datacache_count(datacache **dc)
Definition: datacache.c:78
int xferlog_add(xferlog **log, const time_t timestamp, const uint64_t rx, const uint64_t tx)
Definition: datacache.c:125
void xferlog_debug(xferlog **log, const int newline)
Definition: datacache.c:159
struct datacache datacache
int datacache_activecount(datacache **dc)
Definition: datacache.c:90
void xferlog_clear(xferlog **log)
Definition: datacache.c:148
struct xferlog xferlog
int datacache_remove(datacache **dc, const char *interface)
Definition: datacache.c:27
void datacache_clear(datacache **dc)
Definition: datacache.c:66
void datacache_debug(datacache **dc)
Definition: datacache.c:104
int datacache_add(datacache **dc, const char *interface, const short sync)
Definition: datacache.c:4
short filled
Definition: datacache.h:7
short active
Definition: datacache.h:6
uint64_t currx
Definition: datacache.h:9
time_t updated
Definition: datacache.h:10
struct xferlog * log
Definition: datacache.h:11
short syncneeded
Definition: datacache.h:8
struct datacache * next
Definition: datacache.h:12
uint64_t curtx
Definition: datacache.h:9
char interface[32]
Definition: datacache.h:5
struct xferlog * next
Definition: datacache.h:18
time_t timestamp
Definition: datacache.h:16
uint64_t tx
Definition: datacache.h:17
uint64_t rx
Definition: datacache.h:17