Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/preferences/src/lib/parser/preferences/cmd_line_prefs_reader.h @ 6393

Last change on this file since 6393 was 6393, checked in by rennerc, 18 years ago

added libargp to orxonox

File size: 716 bytes
Line 
1/*!
2 * @file proto_class.h
3 * @brief Definition of CmdLinePrefsReader
4*/
5
6#ifndef _CMD_LINE_PREFS_READER_H
7#define _CMD_LINE_PREFS_READER_H
8
9#include "stdincl.h"
10#include "debug.h"
11
12#include "src/lib/argp/argp.h"
13
14typedef struct {
15  bool isServer;
16  bool isClient;
17  char * host;
18  char * port;
19  char * configFile;
20} CmdLineArgs;
21
22typedef struct argp Argp;
23typedef struct argp_state ArgpState;
24
25//! A class for reading commandline arguments into Preferences
26class CmdLinePrefsReader {
27
28 public:
29   CmdLinePrefsReader(int argc, char** argv);
30   virtual ~CmdLinePrefsReader();
31
32   static error_t parse_opt(int key, char *arg, ArgpState *state);
33
34 private:
35   CmdLineArgs cmdLineArgs;
36
37};
38
39#endif /* _PROTO_CLASS_H */
Note: See TracBrowser for help on using the repository browser.