Wireshark 4.5.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
rtd_table.h
Go to the documentation of this file.
1
12#ifndef __RTD_TABLE_H__
13#define __RTD_TABLE_H__
14
15#include "tap.h"
16#include "timestats.h"
17#include "value_string.h"
18#include <epan/wmem_scopes.h>
19
20#ifdef __cplusplus
21extern "C" {
22#endif /* __cplusplus */
23
24typedef struct _rtd_timestat {
25 unsigned num_timestat;
26 timestat_t* rtd;
27 uint32_t open_req_num;
28 uint32_t disc_rsp_num;
29 uint32_t req_dup_num;
30 uint32_t rsp_dup_num;
32
34typedef struct _rtd_stat_table {
35 char *filter;
36 unsigned num_rtds;
37 rtd_timestat* time_stats;
39
46
48struct register_rtd;
49typedef struct register_rtd register_rtd_t;
50
51typedef void (*rtd_gui_init_cb)(rtd_stat_table* rtd, void* gui_data);
52typedef void (*rtd_filter_check_cb)(const char *opt_arg, const char **filter, char** err);
53
64WS_DLL_PUBLIC void register_rtd_table(const int proto_id, const char* tap_listener, unsigned num_tables, unsigned num_timestats, const value_string* vs_type,
65 tap_packet_cb rtd_packet_func, rtd_filter_check_cb filter_check_cb);
66
72WS_DLL_PUBLIC int get_rtd_proto_id(register_rtd_t* rtd);
73
79WS_DLL_PUBLIC const char* get_rtd_tap_listener_name(register_rtd_t* rtd);
80
86WS_DLL_PUBLIC tap_packet_cb get_rtd_packet_func(register_rtd_t* rtd);
87
93WS_DLL_PUBLIC unsigned get_rtd_num_tables(register_rtd_t* rtd);
94
100WS_DLL_PUBLIC const value_string* get_rtd_value_string(register_rtd_t* rtd);
101
107WS_DLL_PUBLIC register_rtd_t* get_rtd_table_by_name(const char* name);
108
113WS_DLL_PUBLIC void free_rtd_table(rtd_stat_table* table);
114
119WS_DLL_PUBLIC void reset_rtd_table(rtd_stat_table* table);
120
127WS_DLL_PUBLIC void rtd_table_iterate_tables(wmem_foreach_func func, void *user_data);
128
136WS_DLL_PUBLIC void rtd_table_get_filter(register_rtd_t* rtd, const char *opt_arg, const char **filter, char** err);
137
145WS_DLL_PUBLIC void rtd_table_dissector_init(register_rtd_t* rtd, rtd_stat_table* table, rtd_gui_init_cb gui_callback, void *callback_data);
146
153WS_DLL_PUBLIC char* rtd_table_get_tap_string(register_rtd_t* rtd);
154
155#ifdef __cplusplus
156}
157#endif /* __cplusplus */
158
159#endif /* __RTD_TABLE_H__ */
160
161/*
162 * Editor modelines
163 *
164 * Local Variables:
165 * c-basic-offset: 4
166 * tab-width: 8
167 * indent-tabs-mode: nil
168 * End:
169 *
170 * ex: set shiftwidth=4 tabstop=8 expandtab:
171 * :indentSize=4:tabSize=8:noTabs=true:
172 */
bool(* wmem_foreach_func)(const void *key, void *value, void *userdata)
Definition wmem_tree.h:247
struct _rtd_data_t rtd_data_t
WS_DLL_PUBLIC const value_string * get_rtd_value_string(register_rtd_t *rtd)
Definition rtd_table.c:52
struct _rtd_stat_table rtd_stat_table
WS_DLL_PUBLIC register_rtd_t * get_rtd_table_by_name(const char *name)
Definition rtd_table.c:106
WS_DLL_PUBLIC char * rtd_table_get_tap_string(register_rtd_t *rtd)
Definition rtd_table.c:111
WS_DLL_PUBLIC void free_rtd_table(rtd_stat_table *table)
Definition rtd_table.c:85
WS_DLL_PUBLIC void register_rtd_table(const int proto_id, const char *tap_listener, unsigned num_tables, unsigned num_timestats, const value_string *vs_type, tap_packet_cb rtd_packet_func, rtd_filter_check_cb filter_check_cb)
Definition rtd_table.c:60
WS_DLL_PUBLIC void rtd_table_iterate_tables(wmem_foreach_func func, void *user_data)
Definition rtd_table.c:156
WS_DLL_PUBLIC int get_rtd_proto_id(register_rtd_t *rtd)
Definition rtd_table.c:30
WS_DLL_PUBLIC void rtd_table_get_filter(register_rtd_t *rtd, const char *opt_arg, const char **filter, char **err)
Definition rtd_table.c:118
WS_DLL_PUBLIC void rtd_table_dissector_init(register_rtd_t *rtd, rtd_stat_table *table, rtd_gui_init_cb gui_callback, void *callback_data)
Definition rtd_table.c:139
WS_DLL_PUBLIC tap_packet_cb get_rtd_packet_func(register_rtd_t *rtd)
Definition rtd_table.c:43
WS_DLL_PUBLIC void reset_rtd_table(rtd_stat_table *table)
Definition rtd_table.c:98
WS_DLL_PUBLIC const char * get_rtd_tap_listener_name(register_rtd_t *rtd)
Definition rtd_table.c:38
WS_DLL_PUBLIC unsigned get_rtd_num_tables(register_rtd_t *rtd)
Definition rtd_table.c:48
Definition rtd_table.h:42
void * user_data
Definition rtd_table.h:44
rtd_stat_table stat_table
Definition rtd_table.h:43
Definition rtd_table.h:34
unsigned num_rtds
Definition rtd_table.h:36
Definition rtd_table.h:24
unsigned num_timestat
Definition rtd_table.h:25
Definition timestats.h:23
Definition value_string.h:25
Definition rtd_table.c:20