Create this branch to work on loading of different Kernel-Debugger DLL providers...
[reactos.git] / base / applications / network / net / main.c
1 /*
2 * COPYRIGHT: See COPYING in the top level directory
3 * PROJECT: ReactOS net command
4 * FILE:
5 * PURPOSE:
6 *
7 * PROGRAMMERS: Magnus Olsen (greatlord@reactos.org)
8 */
9
10 #include "net.h"
11
12 typedef struct _COMMAND
13 {
14 WCHAR *name;
15 INT (*func)(INT, WCHAR**);
16 // VOID (*help)(INT, WCHAR**);
17 } COMMAND, *PCOMMAND;
18
19 COMMAND cmds[] =
20 {
21 {L"accounts", unimplemented},
22 {L"computer", unimplemented},
23 {L"config", unimplemented},
24 {L"continue", unimplemented},
25 {L"file", unimplemented},
26 {L"group", unimplemented},
27 {L"help", cmdHelp},
28 {L"helpmsg", unimplemented},
29 {L"localgroup", unimplemented},
30 {L"name", unimplemented},
31 {L"print", unimplemented},
32 {L"send", unimplemented},
33 {L"session", unimplemented},
34 {L"share", unimplemented},
35 {L"start", cmdStart},
36 {L"statistics", unimplemented},
37 {L"stop", cmdStop},
38 {L"time", unimplemented},
39 {L"use", unimplemented},
40 {L"user", unimplemented},
41 {L"view", unimplemented},
42
43 };
44
45 int wmain(int argc, WCHAR **argv)
46 {
47 PCOMMAND cmdptr;
48
49 if (argc < 2)
50 {
51 help();
52 return 1;
53 }
54
55 /* Scan the command table */
56 for (cmdptr = cmds; cmdptr->name; cmdptr++)
57 {
58 if (_wcsicmp(argv[1], cmdptr->name) == 0)
59 {
60 return cmdptr->func(argc, argv);
61 }
62 }
63
64 help();
65
66 return 1;
67 }
68
69 INT unimplemented(INT argc, WCHAR **argv)
70 {
71 puts("This command is not implemented yet");
72 return 1;
73 }