1 #ifndef RBX_CONFIG_PARSER
2 #define RBX_CONFIG_PARSER
18 bool is_number() const;
20 bool in_section(std::string prefix
) const;
24 typedef std::vector
< std::pair
<std::string
, Entry
*> > ConfigVector
;
25 typedef std::vector
<Entry
*> EntryList
;
27 ConfigVector variables
;
29 virtual ~ConfigParser();
31 bool load_file(std::string path
);
32 Entry
* parse_line(const char* line
);
33 void import_line(const char* line
);
34 void set(const char* name
, const char* val
);
35 void import_many(std::string string
);
36 void import_stream(std::istream
&);
37 Entry
* find(std::string variable
);
38 EntryList
* get_section(std::string prefix
);
40 void update_configuration(Configuration
*);
41 void parsed_options(std::string
& str
);
44 bool process_internal(std::string key
, std::string val
);