#ifndef PREFERENCES_H
#define PREFERENCES_H
#include <stdbool.h>
#include <unistd.h>
enum {
STATMODE_ACCUM = 1,
STATMODE_DELTA,
STATMODE_EVENT,
STATMODE_NON_EVENT
};
void top_prefs_init(void);
bool top_prefs_set_mode(const char *mode);
int top_prefs_get_mode(void);
const char *top_prefs_get_mode_string(void);
void top_prefs_set_sleep(int seconds);
int top_prefs_get_sleep(void);
bool top_prefs_set_sort(const char *sort);
int top_prefs_get_sort(void);
bool top_prefs_set_secondary_sort(const char *sort);
int top_prefs_get_secondary_sort(void);
const char *top_prefs_get_sort_string(void);
const char *top_prefs_get_secondary_sort_string(void);
void top_prefs_set_ascending(bool flag);
bool top_prefs_get_ascending(void);
void top_prefs_set_frameworks(bool flag);
bool top_prefs_get_frameworks(void);
void top_prefs_set_frameworks_interval(int interval);
int top_prefs_get_frameworks_interval(void);
void top_prefs_set_user(const char *user);
char *top_prefs_get_user(void);
void top_prefs_set_user_uid(uid_t uid);
uid_t top_prefs_get_user_uid(void);
bool top_prefs_set_stats(const char *names);
bool top_prefs_get_stats(int *total, int **array);
int top_prefs_get_samples(void);
void top_prefs_set_samples(int s);
int top_prefs_get_nprocs(void);
void top_prefs_set_nprocs(int n);
void top_prefs_add_pid(pid_t pid);
bool top_prefs_want_pid(pid_t pid);
bool top_prefs_set_signal_string(char *s);
int top_prefs_get_signal(const char **sptr);
void top_prefs_set_logging_mode(bool mode);
bool top_prefs_get_logging_mode(void);
void top_prefs_set_ncols(int limit);
bool top_prefs_get_ncols(int *limit);
void top_prefs_set_swap(bool show);
bool top_prefs_get_swap(void);
void top_prefs_set_secondary_ascending(bool flag);
bool top_prefs_get_secondary_ascending(void);
void top_prefs_set_mmr(bool mmr);
bool top_prefs_get_mmr(void);
#endif