[RAPPS] Bulk install!
[reactos.git] / reactos / base / applications / sc / sc.h
1 #ifndef _SC_PCH_
2 #define _SC_PCH_
3
4 #include <stdarg.h>
5
6 #define WIN32_NO_STATUS
7 #include <windef.h>
8 #include <winbase.h>
9 #include <winsvc.h>
10 #include <sddl.h>
11 #include <tchar.h>
12
13 #include <ndk/rtlfuncs.h>
14 #include <ndk/setypes.h>
15
16
17 #define SCDBG
18
19 typedef struct
20 {
21 LPCTSTR lpServiceName;
22 LPCTSTR lpDisplayName;
23 DWORD dwServiceType;
24 DWORD dwStartType;
25 DWORD dwErrorControl;
26 LPCTSTR lpBinaryPathName;
27 LPCTSTR lpLoadOrderGroup;
28 DWORD dwTagId;
29 LPCTSTR lpDependencies;
30 LPCTSTR lpServiceStartName;
31 LPCTSTR lpPassword;
32
33 BOOL bTagId;
34 } SERVICE_CREATE_INFO, *LPSERVICE_CREATE_INFO;
35
36
37 /* control functions */
38 BOOL Start(LPCTSTR ServiceName, LPCTSTR *ServiceArgs, INT ArgCount);
39 BOOL Create(LPCTSTR *ServiceArgs, INT ArgCount);
40 BOOL Delete(LPCTSTR ServiceName);
41 BOOL Control(DWORD Control, LPCTSTR ServiceName, LPCTSTR *Args, INT ArgCount);
42 BOOL Query(LPCTSTR *ServiceArgs, DWORD ArgCount, BOOL bExtended);
43
44 LPSERVICE_STATUS_PROCESS QueryService(LPCTSTR ServiceName);
45 BOOL SdShow(LPCTSTR ServiceName);
46 BOOL SdSet(LPCTSTR ServiceName, LPCTSTR SecurityDescriptor);
47 BOOL QueryConfig(LPCTSTR ServiceName);
48 BOOL SetConfig(LPCTSTR *ServiceArgs, INT ArgCount);
49 BOOL QueryDescription(LPCTSTR ServiceName);
50 BOOL SetDescription(LPCTSTR ServiceName, LPCTSTR Description);
51 BOOL QueryFailure(LPCTSTR ServiceName);
52 BOOL SetFailure(LPCTSTR *ServiceArgs, INT ArgCount);
53 BOOL GetDisplayName(LPCTSTR ServiceName);
54 BOOL GetKeyName(LPCTSTR ServiceName);
55 BOOL EnumDepend(LPCTSTR ServiceName);
56
57 /* print and error functions */
58 VOID PrintService(LPCTSTR ServiceName, LPSERVICE_STATUS_PROCESS pStatus, BOOL bExtended);
59 VOID PrintServiceStatus(LPSERVICE_STATUS pStatus);
60 VOID ReportLastError(VOID);
61
62 /* misc.c */
63 BOOL
64 ParseCreateConfigArguments(
65 LPCTSTR *ServiceArgs,
66 INT ArgCount,
67 BOOL bChangeService,
68 OUT LPSERVICE_CREATE_INFO lpServiceInfo);
69
70 BOOL
71 ParseFailureArguments(
72 LPCTSTR *ServiceArgs,
73 INT ArgCount,
74 OUT LPCTSTR *ppServiceName,
75 OUT LPSERVICE_FAILURE_ACTIONS pFailureActions);
76
77 /* usage functions */
78 VOID MainUsage(VOID);
79 VOID StartUsage(VOID);
80 VOID PauseUsage(VOID);
81 VOID InterrogateUsage(VOID);
82 VOID ContinueUsage(VOID);
83 VOID StopUsage(VOID);
84 VOID DeleteUsage(VOID);
85 VOID CreateUsage(VOID);
86 VOID ControlUsage(VOID);
87 VOID SdShowUsage(VOID);
88 VOID SdSetUsage(VOID);
89 VOID QueryConfigUsage(VOID);
90 VOID QueryDescriptionUsage(VOID);
91 VOID QueryFailureUsage(VOID);
92 VOID SetDescriptionUsage(VOID);
93 VOID SetConfigUsage(VOID);
94 VOID SetFailureUsage(VOID);
95 VOID GetDisplayNameUsage(VOID);
96 VOID GetKeyNameUsage(VOID);
97 VOID EnumDependUsage(VOID);
98
99 #endif /* _SC_PCH_ */