diff options
Diffstat (limited to 'src/include/gnunet_configuration_lib.h')
-rw-r--r-- | src/include/gnunet_configuration_lib.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/src/include/gnunet_configuration_lib.h b/src/include/gnunet_configuration_lib.h index 68ed570a3..02e656196 100644 --- a/src/include/gnunet_configuration_lib.h +++ b/src/include/gnunet_configuration_lib.h | |||
@@ -113,6 +113,18 @@ GNUNET_CONFIGURATION_default (void); | |||
113 | 113 | ||
114 | 114 | ||
115 | /** | 115 | /** |
116 | * Return the filename of the default configuration filename | ||
117 | * that is used when no explicit configuration entry point | ||
118 | * has been specified. | ||
119 | * | ||
120 | * @returns NULL if no default configuration file can be located, | ||
121 | * a newly allocated string otherwise | ||
122 | */ | ||
123 | char * | ||
124 | GNUNET_CONFIGURATION_default_filename (void); | ||
125 | |||
126 | |||
127 | /** | ||
116 | * Parse a configuration file, add all of the options in the | 128 | * Parse a configuration file, add all of the options in the |
117 | * file to the configuration environment. | 129 | * file to the configuration environment. |
118 | * | 130 | * |
@@ -139,6 +151,19 @@ GNUNET_CONFIGURATION_serialize (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
139 | 151 | ||
140 | 152 | ||
141 | /** | 153 | /** |
154 | * Serializes the given configuration with diagnostics information. | ||
155 | * Diagnostics information will only be available if diagnostics | ||
156 | * have been enabled before parsing. | ||
157 | * | ||
158 | * @param cfg configuration to serialize | ||
159 | * @return the memory block where the serialized configuration is | ||
160 | * present. This memory should be freed by the caller | ||
161 | */ | ||
162 | char * | ||
163 | GNUNET_CONFIGURATION_serialize_diagnostics (const struct | ||
164 | GNUNET_CONFIGURATION_Handle *cfg); | ||
165 | |||
166 | /** | ||
142 | * De-serializes configuration | 167 | * De-serializes configuration |
143 | * | 168 | * |
144 | * @param cfg configuration to update | 169 | * @param cfg configuration to update |
@@ -234,6 +259,16 @@ GNUNET_CONFIGURATION_parse_and_run (const char *filename, | |||
234 | GNUNET_CONFIGURATION_Callback cb, | 259 | GNUNET_CONFIGURATION_Callback cb, |
235 | void *cb_cls); | 260 | void *cb_cls); |
236 | 261 | ||
262 | /** | ||
263 | * Enable extra diagnostics. Will produce more log output | ||
264 | * and allocate more memory. | ||
265 | * | ||
266 | * @param cfg configuration handle | ||
267 | */ | ||
268 | void | ||
269 | GNUNET_CONFIGURATION_enable_diagnostics (struct | ||
270 | GNUNET_CONFIGURATION_Handle *cfg); | ||
271 | |||
237 | 272 | ||
238 | /** | 273 | /** |
239 | * Function to iterate over options. | 274 | * Function to iterate over options. |