diff options
Diffstat (limited to 'src/include/gnunet_namestore_plugin.h')
-rw-r--r-- | src/include/gnunet_namestore_plugin.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/include/gnunet_namestore_plugin.h b/src/include/gnunet_namestore_plugin.h index 5e8ac3203..1df0a5eb0 100644 --- a/src/include/gnunet_namestore_plugin.h +++ b/src/include/gnunet_namestore_plugin.h | |||
@@ -205,6 +205,28 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
205 | GNUNET_NAMESTORE_RecordIterator iter, | 205 | GNUNET_NAMESTORE_RecordIterator iter, |
206 | void *iter_cls); | 206 | void *iter_cls); |
207 | 207 | ||
208 | /** | ||
209 | * Setup the database. | ||
210 | * Note that this will also fail if the database is already initialized. | ||
211 | * See reset_database(). | ||
212 | * | ||
213 | * @param cls closure (internal context for the plugin) | ||
214 | * @param emsg error message on failure. Will be allocated, must be freed. | ||
215 | * @return #GNUNET_OK on success, else fails with #GNUNET_SYSERR | ||
216 | */ | ||
217 | int | ||
218 | (*initialize_database) (void *cls, char **emsg); | ||
219 | |||
220 | /** | ||
221 | * Re-initializes the database. | ||
222 | * DANGEROUS: All existing data in the dabase will be lost! | ||
223 | * | ||
224 | * @param cls closure (internal context for the plugin) | ||
225 | * @param emsg error message on failure. Will be allocated, must be freed. | ||
226 | * @return #GNUNET_OK on success, else fails with #GNUNET_SYSERR | ||
227 | */ | ||
228 | int | ||
229 | (*reset_database) (void *cls, char **emsg); | ||
208 | }; | 230 | }; |
209 | 231 | ||
210 | 232 | ||