My Project
cmdLineParser.h
1 #ifndef CMD_LINE_PARSER_INCLUDED
2 #define CMD_LINE_PARSER_INCLUDED
3 #include <stdarg.h>
4 #include <string.h>
5 
6 #ifdef WIN32
7 int strcasecmp(char* c1,char* c2);
8 #endif
9 
12 public:
14  int set;
15  cmdLineReadable(void);
17  virtual int read(char** argv,int argc);
18 };
19 
21 class cmdLineInt : public cmdLineReadable {
22 public:
24  int value;
25  cmdLineInt();
26  int read(char** argv,int argc);
27 };
30 public:
32  int count;
34  int* value;
35  cmdLineIntArray(int);
36  ~cmdLineIntArray();
37  int read(char** argv,int argc);
38 };
40 class cmdLineFloat : public cmdLineReadable {
41 public:
43  float value;
44  cmdLineFloat();
45  int read(char** argv,int argc);
46 };
49 public:
51  int count;
53  float* value;
54  cmdLineFloatArray(int);
56  int read(char** argv,int argc);
57 };
58 
61 public:
63  char* value;
64  cmdLineString();
65  ~cmdLineString();
66  int read(char** argv,int argc);
67 };
68 
71 public:
73  int count;
75  char** value;
76  cmdLineStringArray(int);
78  int read(char** argv,int argc);
79 };
80 
86 void cmdLineParse(int argc, char **argv,char** names,int num,cmdLineReadable** r);
87 
89 char* GetFileExtension(char* fileName);
90 
91 #endif // CMD_LINE_PARSER_INCLUDED
Definition: cmdLineParser.h:60
Definition: cmdLineParser.h:40
int count
Definition: cmdLineParser.h:73
char ** value
Definition: cmdLineParser.h:75
int * value
Definition: cmdLineParser.h:34
int value
Definition: cmdLineParser.h:24
virtual int read(char **argv, int argc)
Definition: cmdLineParser.cpp:12
Definition: cmdLineParser.h:70
int count
Definition: cmdLineParser.h:32
int count
Definition: cmdLineParser.h:51
float value
Definition: cmdLineParser.h:43
char * value
Definition: cmdLineParser.h:63
Definition: cmdLineParser.h:29
float * value
Definition: cmdLineParser.h:53
Definition: cmdLineParser.h:48
Definition: cmdLineParser.h:21
Definition: cmdLineParser.h:11