#include <glib.h>
#include <epan/range.h>
#include <epan/frame_data.h>
#include <epan/cfile.h>
Go to the source code of this file.
|
|
typedef struct packet_range_tag | packet_range_t |
| | Fully describes a packet range selection, including UI settings, derived counts, and dependency sets used when iterating over a capture file.
|
| |
|
typedef struct packet_range_iter | packet_range_iter_t |
| |
|
|
uint32_t | curr_selected_frame |
| |
Packet range routines (save, print, ...)
Dick Gooris goori.nosp@m.s@lu.nosp@m.cent..nosp@m.com Ulf Lamping ulf.l.nosp@m.ampi.nosp@m.ng@we.nosp@m.b.de
Wireshark - Network traffic analyzer By Gerald Combs geral.nosp@m.d@wi.nosp@m.resha.nosp@m.rk.o.nosp@m.rg Copyright 1998 Gerald Combs
SPDX-License-Identifier: GPL-2.0-or-later
◆ packet_range_e
Selects which subset of packets in a capture file should be processed.
| Enumerator |
|---|
| range_process_all | Process all packets in the capture file
|
| range_process_selected | Process only the currently selected packet(s)
|
| range_process_marked | Process only marked packets
|
| range_process_marked_range | Process packets in the contiguous range between the first and last marked packet
|
| range_process_user_range | Process packets within a user-specified range string
|
◆ range_process_e
Disposition returned per-packet by the range enumeration callback to control iteration.
| Enumerator |
|---|
| range_process_this | Process the current packet and continue to the next
|
| range_process_next | Skip the current packet and continue to the next
|
| range_processing_finished | Stop iteration; all required packets have been processed
|
◆ packet_range_check()
Check whether the packet range is OK.
- Parameters
-
| range | Pointer to the packet_range_t structure to be checked. |
- Returns
- convert_ret_t The result of the check.
◆ packet_range_cleanup()
Cleanup the range structure before the caller frees "range".
- Parameters
-
| range | Pointer to the packet_range_t structure to be cleaned up. |
◆ packet_range_convert_selection_str()
| void packet_range_convert_selection_str |
( |
packet_range_t * |
range, |
|
|
const char * |
es |
|
) |
| |
|
extern |
Convert a selection string to a packet range.
This function takes a selection string and converts it into a packet range structure.
- Parameters
-
| range | Pointer to the packet_range_t structure where the result will be stored. |
| es | The selection string to convert. |
◆ packet_range_convert_str()
| void packet_range_convert_str |
( |
packet_range_t * |
range, |
|
|
const char * |
es |
|
) |
| |
|
extern |
Convert a user-given string to an internal selection specified range representation.
- Parameters
-
| range | Pointer to the packet_range_t structure where the result will be stored. |
| es | The user-given string representing the packet range. |
◆ packet_range_count()
Return the number of packets that will be processed.
- Parameters
-
| range | Pointer to the packet_range_t structure. |
- Returns
- uint32_t The number of packets that will be processed.
- Note
- If live capture is occurring, the actual number of packets that will be processed may be greater; i.e., packets that are captured after this function is called may be included as well.
◆ packet_range_init()
Initialize a packet range structure.
- Parameters
-
| range | Pointer to the packet_range_t structure to be initialized. |
| cf | Pointer to the capture_file structure associated with the packet range. |
◆ packet_range_iter_init()
Initialize an iterator over a packet range.
This function will call packet_range_process_init on range, so that does not need to be called beforehand.
- Parameters
-
| iter | Pointer to the packet_range_iter_t structure to initialize. |
| range | Pointer to the packet_range_t over which to iterate. |
◆ packet_range_iter_next()
Get the next frame data to process from a packet range.
- Parameters
-
| iter | Pointer to the packet_range_iter_t iterator. |
- Returns
- frame_data* The frame data to process. NULL when iteration is done.
◆ packet_range_process_all()
Check if all packets in the range need to be processed.
- Parameters
-
| range | Pointer to the packet_range_t structure. |
- Returns
- bool True if all packets need to be processed, false otherwise.
◆ packet_range_process_init()
Initialize the processing run for a packet range.
- Parameters
-
| range | Pointer to the packet_range_t structure to initialize. |
◆ packet_range_process_packet()
Check if a packet should be processed based on the given range.
- Parameters
-
| range | Pointer to the packet range structure. |
| fdata | Pointer to the frame data structure representing the packet to be checked. |
- Returns
- convert_ret_t The result of the check, indicating whether the packet should be processed or not.