Added new Service Control utitlity.
[reactos.git] / reactos / apps / utils / sc / main.h
1 /*
2 * ReactOS test program -
3 *
4 * main.h
5 *
6 * Copyright (C) 2002 Robert Dickenson <robd@reactos.org>
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21 */
22
23 #ifndef __MAIN_H__
24 #define __MAIN_H__
25
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29
30
31 DWORD ReportLastError(void);
32 long getinput(char* Buffer, int buflen);
33 void dprintf(char* fmt, ...);
34
35 typedef enum tag_SC_CMDS {
36 SC_CMD_QUERY,
37 SC_CMD_QUERYEX,
38 SC_CMD_START,
39 SC_CMD_PAUSE,
40 SC_CMD_INTERROGATE,
41 SC_CMD_CONTINUE,
42 SC_CMD_STOP,
43 SC_CMD_CONFIG,
44 SC_CMD_DESCRIPTION,
45 SC_CMD_FAILURE,
46 SC_CMD_QC,
47 SC_CMD_QDESCRIPTION,
48 SC_CMD_QFAILURE,
49 SC_CMD_DELETE,
50 SC_CMD_CREATE,
51 SC_CMD_CONTROL,
52 SC_CMD_SDSHOW,
53 SC_CMD_SDSET,
54 SC_CMD_GETDISPLAYNAME,
55 SC_CMD_GETKEYNAME,
56 SC_CMD_ENUMDEPEND,
57 SC_CMD_BOOT,
58 SC_CMD_LOCK,
59 SC_CMD_QUERYLOCK
60 } SC_CMDS;
61
62 int sc_query(SC_HANDLE hSCManager, SC_CMDS sc_cmd, char* argv[]);
63 int sc_setup(SC_HANDLE hSCManager, SC_CMDS sc_cmd, char* argv[]);
64 int sc_config(SC_HANDLE hSCManager, SC_CMDS sc_cmd, char* argv[]);
65 int sc_command(SC_HANDLE hSCManager, SC_CMDS sc_cmd, char* argv[]);
66
67
68 #ifdef __cplusplus
69 };
70 #endif
71
72 #endif // __MAIN_H__