index 446c8672ff890edd7a3180047ba7897677410b03..6a679ce8a17baa5900573ee38cf0deb3e22882cb 100644 (file)
/*
* sdb_plugin_load:
* Load (any type of) plugin by loading the shared object file and calling the
- * sdb_module_init function.
+ * sdb_module_init function. If specified, 'plugin_ctx' fine-tunes the
+ * behavior of the plugin.
*/
int
-sdb_plugin_load(const char *name);
+sdb_plugin_load(const char *name, const sdb_plugin_ctx_t *plugin_ctx);
/*
* sdb_plugin_set_info:
* plugin has been called. It may be used to pass around various information
* between the different component of the library without having each and
* every plugin care about it.
+ *
+ * If non-NULL, sdb_plugin_set_ctx stores the previous context in the location
+ * pointed to be 'old'.
*/
sdb_plugin_ctx_t
sdb_plugin_get_ctx(void);
-sdb_plugin_ctx_t
-sdb_plugin_set_ctx(sdb_plugin_ctx_t ctx);
+int
+sdb_plugin_set_ctx(sdb_plugin_ctx_t ctx, sdb_plugin_ctx_t *old);
/*
* sdb_plugin_configure: