|
ekg2
GIT master
|
#include "ekg2.h"#include <gmodule.h>#include <stdlib.h>#include <stdarg.h>#include <string.h>#include <unistd.h>#include <errno.h>#include "objects.h"#include "abort.h"
Funkcje | |
| static gint | plugin_register_compare (gconstpointer a, gconstpointer b) |
| static void | plugins_add (plugin_t *pl) |
| void | plugins_unlink (plugin_t *pl) |
| void | query_free_data (query_t *data) |
| static void | queries_list_add (query_t **lista, query_t *new_) |
| static void | queries_list_remove (query_t **lista, query_t *elem) |
| void | queries_list_destroy (query_t **lista) |
| void | ekg2_dlinit (const gchar *argv0) |
| int | ekg2_dlclose (GModule *plugin) |
| static GModule * | ekg2_dlopen (const char *name) |
| static void * | ekg2_dlsym (GModule *plugin, char *name) |
| int | plugin_load (const char *name, int prio, int quiet) |
| plugin_t * | plugin_find (const char *name) |
| plugin_t * | plugin_find_uid (const char *uid) |
| int | plugin_unload (plugin_t *p) |
| int | plugin_register (plugin_t *p, int prio) |
| int | plugin_unregister (plugin_t *p) |
| int | plugin_var_find (plugin_t *pl, const char *name) |
| int | plugin_var_add (plugin_t *pl, const char *name, int type, const char *value, int secret, plugin_notify_func_t *notify) |
| static void | registered_query_free_data (query_def_t *data) |
| void | registered_queries_free () |
| static int | query_register_common (const char *name, query_def_t **res) |
| int | query_register (const char *name,...) |
| int | query_register_const (const query_def_t *def) |
| int | query_free (query_t *g) |
| query_t * | query_connect (plugin_t *plugin, const char *name, query_handler_func_t *handler, void *data) |
| static int | query_emit_inner (query_t *g, va_list ap) |
| int | query_emit (plugin_t *plugin, const char *name,...) |
| static int | query_compare (const query_t *data1, const query_t *data2) |
| void | queries_reconnect () |
| int | have_plugin_of_class (plugin_class_t pclass) |
| int | watch_timeout_set (watch_t *o, time_t v) |
| int | plugin_abi_version (int plugin_abi_ver, const char *plugin_name) |
Zmienne | |
| GSList * | plugins = NULL |
| gchar * | rel_plugin_dir = NULL |
| list_t | watches = NULL |
| query_t * | queries [64] |
| query_def_t * | registered_queries |
| int | registered_queries_count = 0 |
| int ekg2_dlclose | ( | GModule * | plugin | ) |
Close handler to dynamic loaded library.
| plugin | - Handler to loaded library. |
| void ekg2_dlinit | ( | const gchar * | argv0 | ) |
|
static |
Load dynamic library file from name
| name | - Full path of library to load. |
|
static |
Get symbol with name from loaded dynamic library.
| plugin | - Pointer to the loaded library. |
| name | - Name of symbol to lookup. |
| int have_plugin_of_class | ( | plugin_class_t | pclass | ) |
Check if we have loaded plugin from pclass
| pclass |
| int plugin_abi_version | ( | int | plugin_abi_ver, |
| const char * | plugin_name | ||
| ) |
| plugin_t* plugin_find | ( | const char * | name | ) |
Find plugin by name
| name | - name of plugin_t |
| plugin_t* plugin_find_uid | ( | const char * | uid | ) |
Find PLUGIN_PROTOCOL plugin which can handle uid
| int plugin_load | ( | const char * | name, |
| int | prio, | ||
| int | quiet | ||
| ) |
| int plugin_register | ( | plugin_t * | p, |
| int | prio | ||
| ) |
|
static |
| int plugin_unload | ( | plugin_t * | p | ) |
| int plugin_unregister | ( | plugin_t * | p | ) |
| int plugin_var_add | ( | plugin_t * | pl, |
| const char * | name, | ||
| int | type, | ||
| const char * | value, | ||
| int | secret, | ||
| plugin_notify_func_t * | notify | ||
| ) |
| int plugin_var_find | ( | plugin_t * | pl, |
| const char * | name | ||
| ) |
it looks for given variable name in given plugin
| pl | - plugin |
| name | - variable name |
returns sequence number+1 of variable if found, else 0
|
static |
| void plugins_unlink | ( | plugin_t * | pl | ) |
| void queries_list_destroy | ( | query_t ** | lista | ) |
| void queries_reconnect | ( | ) |
Reconnect (resort) all queries, e.g. after plugin prio change.
| query_t* query_connect | ( | plugin_t * | plugin, |
| const char * | name, | ||
| query_handler_func_t * | handler, | ||
| void * | data | ||
| ) |
| int query_emit | ( | plugin_t * | plugin, |
| const char * | name, | ||
| ... | |||
| ) |
|
static |
| int query_free | ( | query_t * | g | ) |
| void query_free_data | ( | query_t * | data | ) |
| int query_register | ( | const char * | name, |
| ... | |||
| ) |
|
static |
| int query_register_const | ( | const query_def_t * | def | ) |
| void registered_queries_free | ( | ) |
|
static |
| int watch_timeout_set | ( | watch_t * | o, |
| time_t | v | ||
| ) |
| GSList* plugins = NULL |
| query_t* queries[64] |
| query_def_t* registered_queries |
| int registered_queries_count = 0 |
| gchar* rel_plugin_dir = NULL |
1.8.13