Keep track of what search terms we have seen, and how frequently each has been seen.
|
Data Structures |
| struct | term_counts |
| | This is what the stat_hash's 'val' points to. More...
|
Functions |
| | RCSID ("$Id:search_stats.c, v 1.21 2005/12/17 09:25:45 daichik Exp $") |
| gboolean | delete_hash_entry (gpointer key, gpointer val, gpointer data) |
| void | empty_hash_table (void) |
| gboolean | stats_hash_to_treeview (gpointer key, gpointer value, gpointer userdata) |
| | Helper func for stats_display - does two things:.
|
| void | search_stats_tally (const word_vec_t *vec) |
| | Count a word that has been seen.
|
| void | search_stats_notify_word (query_type_t type, const gchar *search, const host_addr_t unused_addr, guint16 unused_port) |
| void | search_stats_notify_whole (query_type_t type, const gchar *search, const host_addr_t unused_addr, guint16 unused_port) |
| void | search_stats_notify_routed (query_type_t unused_type, const gchar *unused_search, const host_addr_t addr, guint16 port) |
| void | search_stats_gui_enable (search_request_listener_t lst) |
| | Enable search stats.
|
| void | search_stats_gui_disable (void) |
| void | search_stats_gui_reset (void) |
| | Clear the list, empty the hash table.
|
| void | search_stats_gui_set_type (gint type) |
| void | add_column (GtkTreeView *treeview, gint id, gfloat xalign, const gchar *label) |
| void | search_stats_gui_init (void) |
| void | search_stats_gui_shutdown (void) |
| void | search_stats_gui_update (time_t now) |
| | Display the data gathered during the last time period.
|
Variables |
| guint | stat_count = 0 |
| GHashTable * | stat_hash = NULL |
| GtkListStore * | store_search_stats = NULL |
| GtkTreeView * | treeview_search_stats = NULL |
| GtkLabel * | label_search_stats_count = NULL |
| gboolean | callback_registered = FALSE |
| gint | selected_type = NO_SEARCH_STATS |