23 #ifndef INCLUDED_GR_PREFS_H
24 #define INCLUDED_GR_PREFS_H
33 typedef std::map< std::string, std::map<std::string, std::string> >
config_map_t;
34 typedef std::map< std::string, std::map<std::string, std::string> >::iterator
config_map_itr;
48 static prefs *singleton();
49 static void set_singleton(
prefs *p);
57 std::string to_string();
70 virtual bool has_section(
const std::string §ion);
75 virtual bool has_option(
const std::string §ion,
76 const std::string &option);
82 virtual const std::string get_string(
const std::string §ion,
83 const std::string &option,
84 const std::string &default_val);
90 virtual void set_string(
const std::string §ion,
91 const std::string &option,
92 const std::string &val);
98 virtual bool get_bool(
const std::string §ion,
99 const std::string &option,
105 virtual void set_bool(
const std::string §ion,
106 const std::string &option,
113 virtual long get_long(
const std::string §ion,
114 const std::string &option,
120 virtual void set_long(
const std::string §ion,
121 const std::string &option,
128 virtual double get_double(
const std::string §ion,
129 const std::string &option,
135 virtual void set_double(
const std::string §ion,
136 const std::string &option,
140 virtual std::vector<std::string> _sys_prefs_filenames();
141 virtual void _read_files();
142 virtual void _convert_to_map(
const std::string &conf);
143 virtual char * option_to_env(std::string section, std::string option);
std::map< std::string, std::map< std::string, std::string > >::iterator config_map_itr
Definition: prefs.h:34
std::map< std::string, std::string >::iterator config_map_elem_itr
Definition: prefs.h:36
#define GR_RUNTIME_API
Definition: gnuradio-runtime/include/gnuradio/api.h:30
Base class for representing user preferences a la windows INI files.The real implementation is in Pyt...
Definition: prefs.h:45
boost::mutex mutex
Definition: thread.h:46
std::map< std::string, std::string > config_map_elem_t
Definition: prefs.h:35
std::map< std::string, std::map< std::string, std::string > > config_map_t
Definition: prefs.h:33