| Wireshark 4.7.3 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
srt_table.h
Go to the documentation of this file.
1
10#pragma once
11#include "tap.h"
12#include "timestats.h"
13#include <epan/wmem_scopes.h>
14
15#ifdef __cplusplus
16 extern "C" {
17#endif /* __cplusplus */
18
20 typedef struct _srt_procedure_t {
21 int proc_index;
22 timestat_t stats;
23 char *procedure;
24} srt_procedure_t;
25
27 typedef struct _srt_stat_table {
28 const char *name;
29 const char *short_name;
30 char *filter_string;
32 int num_procs;
33 const char *proc_column_name;
34 srt_procedure_t *procedures;
35 void* table_specific_data;
36} srt_stat_table;
37
38 struct register_srt;
39 struct _srt_data_t;
40 typedef void (*srt_proc_table_cb)(srt_stat_table* rst, int indx, struct _srt_data_t* gui_data);
41 typedef void (*srt_init_cb)(struct register_srt* srt, GArray* srt_array);
42 typedef unsigned (*srt_param_handler_cb)(struct register_srt* srt, const char* opt_arg, char** err);
43
46 typedef struct _srt_data_t {
47 GArray *srt_array;
48 void *user_data;
49} srt_data_t;
50
52 typedef struct register_srt register_srt_t;
53
56 extern void srt_table_init(void);
57
67WS_DLL_PUBLIC void register_srt_table(const int proto_id, const char* tap_listener, int max_tables,
68 tap_packet_cb srt_packet_func, srt_init_cb init_cb, srt_param_handler_cb param_cb);
69
75WS_DLL_PUBLIC int get_srt_proto_id(register_srt_t* srt);
76
82WS_DLL_PUBLIC const char* get_srt_tap_listener_name(register_srt_t* srt);
83
89WS_DLL_PUBLIC int get_srt_max_tables(register_srt_t* srt);
90
96WS_DLL_PUBLIC tap_packet_cb get_srt_packet_func(register_srt_t* srt);
97
104WS_DLL_PUBLIC void set_srt_table_param_data(register_srt_t* srt, void* data);
105
111WS_DLL_PUBLIC void* get_srt_table_param_data(register_srt_t* srt);
112
118WS_DLL_PUBLIC register_srt_t* get_srt_table_by_name(const char* name);
119
124WS_DLL_PUBLIC void free_srt_table_data(srt_stat_table *rst);
125
131WS_DLL_PUBLIC void free_srt_table(register_srt_t *srt, GArray* srt_array);
132
137WS_DLL_PUBLIC void reset_srt_table(GArray* srt_array);
138
145WS_DLL_PUBLIC void srt_table_iterate_tables(wmem_foreach_func func, void *user_data);
146
154WS_DLL_PUBLIC void srt_table_get_filter(register_srt_t* srt, const char *opt_arg, const char **filter, char** err);
155
161WS_DLL_PUBLIC void srt_table_dissector_init(register_srt_t* srt, GArray* srt_array);
162
169WS_DLL_PUBLIC char* srt_table_get_tap_string(register_srt_t* srt);
170
176WS_DLL_PUBLIC srt_param_handler_cb srt_table_get_param_handler_cb(register_srt_t* srt);
177
189WS_DLL_PUBLIC srt_stat_table* init_srt_table(const char *name, const char *short_name, GArray *srt_array, int num_procs, const char* proc_column_name,
190 const char *filter_string, void* table_specific_data);
191
198WS_DLL_PUBLIC void init_srt_table_row(srt_stat_table *rst, int proc_index, const char *procedure);
199
207WS_DLL_PUBLIC void add_srt_table_data(srt_stat_table *rst, int proc_index, const nstime_t *req_time, packet_info *pinfo);
208
209#ifdef __cplusplus
210}
211#endif /* __cplusplus */
212
213/*
214 * Editor modelines
215 *
216 * Local Variables:
217 * c-basic-offset: 4
218 * tab-width: 8
219 * indent-tabs-mode: nil
220 * End:
221 *
222 * ex: set shiftwidth=4 tabstop=8 expandtab:
223 * :indentSize=4:tabSize=8:noTabs=true:
224 */
packet_info
struct _packet_info packet_info
Represents the metadata and indexing information for a single captured frame.
wmem_foreach_func
bool(* wmem_foreach_func)(const void *key, void *value, void *userdata)
Function type for processing one node of a tree during a traversal.
Definition wmem_tree.h:389
srt_table_get_filter
WS_DLL_PUBLIC void srt_table_get_filter(register_srt_t *srt, const char *opt_arg, const char **filter, char **err)
Definition srt_table.c:141
register_srt_table
WS_DLL_PUBLIC void register_srt_table(const int proto_id, const char *tap_listener, int max_tables, tap_packet_cb srt_packet_func, srt_init_cb init_cb, srt_param_handler_cb param_cb)
Definition srt_table.c:181
srt_table_get_param_handler_cb
WS_DLL_PUBLIC srt_param_handler_cb srt_table_get_param_handler_cb(register_srt_t *srt)
Definition srt_table.c:136
get_srt_table_param_data
WS_DLL_PUBLIC void * get_srt_table_param_data(register_srt_t *srt)
Definition srt_table.c:58
reset_srt_table
WS_DLL_PUBLIC void reset_srt_table(GArray *srt_array)
Definition srt_table.c:109
srt_table_get_tap_string
WS_DLL_PUBLIC char * srt_table_get_tap_string(register_srt_t *srt)
Definition srt_table.c:129
get_srt_tap_listener_name
WS_DLL_PUBLIC const char * get_srt_tap_listener_name(register_srt_t *srt)
Definition srt_table.c:38
get_srt_table_by_name
WS_DLL_PUBLIC register_srt_t * get_srt_table_by_name(const char *name)
Definition srt_table.c:124
init_srt_table
WS_DLL_PUBLIC srt_stat_table * init_srt_table(const char *name, const char *short_name, GArray *srt_array, int num_procs, const char *proc_column_name, const char *filter_string, void *table_specific_data)
Definition srt_table.c:209
srt_table_dissector_init
WS_DLL_PUBLIC void srt_table_dissector_init(register_srt_t *srt, GArray *srt_array)
Definition srt_table.c:170
free_srt_table
WS_DLL_PUBLIC void free_srt_table(register_srt_t *srt, GArray *srt_array)
Definition srt_table.c:79
srt_table_iterate_tables
WS_DLL_PUBLIC void srt_table_iterate_tables(wmem_foreach_func func, void *user_data)
Definition srt_table.c:203
set_srt_table_param_data
WS_DLL_PUBLIC void set_srt_table_param_data(register_srt_t *srt, void *data)
Definition srt_table.c:53
free_srt_table_data
WS_DLL_PUBLIC void free_srt_table_data(srt_stat_table *rst)
Definition srt_table.c:64
get_srt_packet_func
WS_DLL_PUBLIC tap_packet_cb get_srt_packet_func(register_srt_t *srt)
Definition srt_table.c:48
register_srt_t
struct register_srt register_srt_t
Definition srt_table.h:52
srt_table_init
void srt_table_init(void)
Definition srt_table.c:175
get_srt_max_tables
WS_DLL_PUBLIC int get_srt_max_tables(register_srt_t *srt)
Definition srt_table.c:43
srt_data_t
struct _srt_data_t srt_data_t
srt_stat_table
struct _srt_stat_table srt_stat_table
init_srt_table_row
WS_DLL_PUBLIC void init_srt_table_row(srt_stat_table *rst, int proc_index, const char *procedure)
Definition srt_table.c:236
add_srt_table_data
WS_DLL_PUBLIC void add_srt_table_data(srt_stat_table *rst, int proc_index, const nstime_t *req_time, packet_info *pinfo)
Definition srt_table.c:256
srt_procedure_t
struct _srt_procedure_t srt_procedure_t
get_srt_proto_id
WS_DLL_PUBLIC int get_srt_proto_id(register_srt_t *srt)
Definition srt_table.c:30
_srt_data_t
Definition srt_table.h:46
_srt_data_t::srt_array
GArray * srt_array
Definition srt_table.h:47
_srt_data_t::user_data
void * user_data
Definition srt_table.h:48
_srt_procedure_t
Definition srt_table.h:20
_srt_procedure_t::procedure
char * procedure
Definition srt_table.h:23
_srt_procedure_t::stats
timestat_t stats
Definition srt_table.h:22
_srt_stat_table
Definition srt_table.h:27
_srt_stat_table::proc_column_name
const char * proc_column_name
Definition srt_table.h:33
_srt_stat_table::short_name
const char * short_name
Definition srt_table.h:29
_srt_stat_table::filter_string
char * filter_string
Definition srt_table.h:30
_srt_stat_table::name
const char * name
Definition srt_table.h:28
_srt_stat_table::procedures
srt_procedure_t * procedures
Definition srt_table.h:34
_srt_stat_table::num_procs
int num_procs
Definition srt_table.h:32
nstime_t
Definition nstime.h:26
register_srt
Definition srt_table.c:20
tap.h
timestats.h
timestat_t
struct _timestat_t timestat_t
Accumulates time delay samples for computing min, max, total, and variance statistics over a set of m...
wmem_scopes.h