2021-11-30 13:01:36 +00:00
|
|
|
/** @file
|
2001-06-12 06:32:39 +00:00
|
|
|
*
|
2006-05-21 05:12:17 +00:00
|
|
|
* Wireshark - Network traffic analyzer
|
|
|
|
* By Gerald Combs <gerald@wireshark.org>
|
2001-06-12 06:32:39 +00:00
|
|
|
* Copyright 1998 Gerald Combs
|
2002-08-28 21:04:11 +00:00
|
|
|
*
|
2018-02-07 11:26:45 +00:00
|
|
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
2001-06-12 06:32:39 +00:00
|
|
|
*/
|
2001-03-22 23:54:47 +00:00
|
|
|
|
2014-06-30 21:08:24 +00:00
|
|
|
#ifndef __UI_PROTO_HIER_STATS_H__
|
|
|
|
#define __UI_PROTO_HIER_STATS_H__
|
2001-03-22 23:54:47 +00:00
|
|
|
|
2021-03-16 20:50:13 +00:00
|
|
|
#include <epan/proto.h>
|
|
|
|
#include "cfile.h"
|
|
|
|
|
2015-02-03 16:39:14 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif /* __cplusplus */
|
|
|
|
|
|
|
|
/** @file
|
|
|
|
* Protocol Hierarchy Statistics
|
|
|
|
*/
|
|
|
|
|
2001-03-22 23:54:47 +00:00
|
|
|
typedef struct {
|
2017-11-29 00:03:11 +00:00
|
|
|
header_field_info *hfinfo;
|
|
|
|
guint num_pkts_total;
|
2022-04-08 03:44:27 +00:00
|
|
|
guint num_pdus_total;
|
2017-11-29 00:03:11 +00:00
|
|
|
guint num_pkts_last;
|
|
|
|
guint num_bytes_total;
|
|
|
|
guint num_bytes_last;
|
2022-04-08 03:44:27 +00:00
|
|
|
guint last_pkt;
|
2001-03-22 23:54:47 +00:00
|
|
|
} ph_stats_node_t;
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct {
|
2017-11-29 00:03:11 +00:00
|
|
|
guint tot_packets;
|
|
|
|
guint tot_bytes;
|
|
|
|
GNode *stats_tree;
|
|
|
|
double first_time; /* seconds (msec resolution) of first packet */
|
|
|
|
double last_time; /* seconds (msec resolution) of last packet */
|
2001-03-22 23:54:47 +00:00
|
|
|
} ph_stats_t;
|
|
|
|
|
2017-12-03 18:53:58 +00:00
|
|
|
ph_stats_t *ph_stats_new(capture_file *cf);
|
2001-03-22 23:54:47 +00:00
|
|
|
|
|
|
|
void ph_stats_free(ph_stats_t *ps);
|
|
|
|
|
2015-02-03 16:39:14 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif /* __cplusplus */
|
|
|
|
|
2014-10-14 19:58:21 +00:00
|
|
|
#endif /* __UI_PROTO_HIER_STATS_H__ */
|