xref: /freebsd/usr.bin/top/commands.h (revision 734e82fe33aa764367791a7d603b383996c6b40b)
1 /*
2  *  Top users/processes display for Unix
3  *  Version 3
4  *
5  *  This program may be freely redistributed,
6  *  but this entire comment MUST remain intact.
7  *
8  *  Copyright (c) 1984, 1989, William LeFebvre, Rice University
9  *  Copyright (c) 1989, 1990, 1992, William LeFebvre, Northwestern University
10  *  Copyright (c) 2016, Randy Westlund
11  */
12 #ifndef COMMANDS_H
13 #define COMMANDS_H
14 
15 void	show_errors(void);
16 int	error_count(void);
17 void	show_help(void);
18 
19 enum cmd_id {
20 	CMD_NONE,
21 	CMD_redraw,
22 	CMD_update,
23 	CMD_quit,
24 	CMD_help,
25 	CMD_grep,
26 	CMD_errors,
27 	CMD_number,
28 	CMD_delay,
29 	CMD_displays,
30 	CMD_kill,
31 	CMD_renice,
32 	CMD_idletog,
33 	CMD_user,
34 	CMD_selftog,
35 	CMD_thrtog,
36 	CMD_viewtog,
37 	CMD_viewsys,
38 	CMD_wcputog,
39 	CMD_showargs,
40 	CMD_jidtog,
41 	CMD_kidletog,
42 	CMD_pcputog,
43 	CMD_jail,
44 	CMD_swaptog,
45 	CMD_order,
46 	CMD_pid	,
47 	CMD_toggletid,
48 };
49 
50 struct command {
51 	char c;
52 	const char * const desc;
53 	bool available_to_dumb;
54 	enum cmd_id id;
55 };
56 
57 extern const struct command all_commands[];
58 
59 #endif /* COMMANDS_H */
60