Changeset 4597 in orxonox.OLD for orxonox/trunk/src/lib/util/ini_parser.h
- Timestamp:
- Jun 11, 2005, 12:55:48 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/lib/util/ini_parser.h
r4482 r4597 2 2 \file ini_parser.h 3 3 \brief A small ini file parser 4 4 5 5 Can be used to find a defined [Section] in an ini file and get the VarName=Value entries 6 6 */ … … 12 12 #include <string.h> 13 13 #include <stdlib.h> 14 #include "base_object.h" 14 15 15 16 #define PARSELINELENGHT 512 //!< how many chars to read at once … … 17 18 //! ini-file parser 18 19 /** 19 20 This class can be used to load an initializer file and parse it's contents for variablename=value pairs. 20 21 */ 21 class IniParser { 22 class IniParser : public BaseObject 23 { 22 24 public: 23 25 IniParser (const char* filename); 24 26 ~IniParser (); 25 27 26 28 char* getVar(const char* name, char* section, char* defvalue); 27 29 int openFile(const char* name); … … 33 35 bool bInSection; //!< if the requested parameter is in the section. 34 36 char internbuf[PARSELINELENGHT]; //!< a buffer 35 37 36 38 37 39 };
Note: See TracChangeset
for help on using the changeset viewer.