aboutsummaryrefslogtreecommitdiff
path: root/src/test/params.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/params.cpp')
-rw-r--r--src/test/params.cpp33
1 files changed, 0 insertions, 33 deletions
diff --git a/src/test/params.cpp b/src/test/params.cpp
deleted file mode 100644
index bb62047..0000000
--- a/src/test/params.cpp
+++ /dev/null
@@ -1,33 +0,0 @@
1#include <stdio.h>
2#include "pproc.h"
3
4int main( int argc, char *argv[] )
5{
6 bool bOn = false;
7 bool bOff = true;
8 bool bTog = false;
9 char cChar = '?';
10 PPROC table[] = {
11 { "boolon", 'n', PPROC_BOOL_TRUE, NULL, &bOn,
12 "Set the bool on." },
13 { "booloff", 'f', PPROC_BOOL_FALSE, NULL, &bOff,
14 "Set the bool off." },
15 { "booltog", 't', PPROC_BOOL_TOGGLE, NULL, &bTog,
16 "Set the bool off." },
17 { "char", 'c', PPROC_CHAR, NULL, &cChar,
18 "Set the char." },
19 { NULL, '\0',0, NULL, NULL,
20 NULL }
21 };
22
23 processParams( argc, argv, table );
24
25 printf("Final results:\n");
26 printf("\tbOn = %s\n", (bOn ? "true" : "false") );
27 printf("\tbOff = %s\n", (bOff ? "true" : "false") );
28 printf("\tbTog = %s\n", (bTog ? "true" : "false") );
29 printf("\tcChar = '%c'\n", cChar );
30
31 return 0;
32}
33