Wireshark 4.7.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
Public Attributes | List of all members
print_stream_ops Struct Reference

Vtable of operations implementing a print stream backend for rendering dissection output. More...

#include <print_stream.h>

Public Attributes

bool(* print_preamble )(struct print_stream *self, char *filename, const char *version_string)
 Outputs any preamble required by the print format before the first line of content.
 
bool(* print_line )(struct print_stream *self, int indent, const char *line)
 Prints a single line of text at the specified indentation level.
 
bool(* print_line_color )(struct print_stream *self, int indent, const char *line, const color_t *fg, const color_t *bg)
 Prints a single line of text with explicit foreground and background colors.
 
bool(* print_bookmark )(struct print_stream *self, const char *name, const char *title)
 Inserts a named bookmark anchor at the current position in the output.
 
bool(* new_page )(struct print_stream *self)
 Advances the output to a new page, if supported by the print format.
 
bool(* print_finale )(struct print_stream *self)
 Outputs any finale or closing content required by the print format after all lines.
 
bool(* destroy )(struct print_stream *self)
 Destroys the print stream and releases all associated resources.
 

Detailed Description

Vtable of operations implementing a print stream backend for rendering dissection output.

Member Data Documentation

◆ destroy

bool(* print_stream_ops::destroy) (struct print_stream *self)

Destroys the print stream and releases all associated resources.

Parameters
selfThe print stream instance to destroy.
Returns
True on success, false if cleanup encountered an error.

◆ new_page

bool(* print_stream_ops::new_page) (struct print_stream *self)

Advances the output to a new page, if supported by the print format.

Parameters
selfThe print stream instance.
Returns
True on success, false on write failure.

◆ print_bookmark

bool(* print_stream_ops::print_bookmark) (struct print_stream *self, const char *name, const char *title)

Inserts a named bookmark anchor at the current position in the output.

Parameters
selfThe print stream instance.
nameInternal identifier for the bookmark.
titleHuman-readable title associated with the bookmark.
Returns
True on success, false on write failure.

◆ print_finale

bool(* print_stream_ops::print_finale) (struct print_stream *self)

Outputs any finale or closing content required by the print format after all lines.

Parameters
selfThe print stream instance.
Returns
True on success, false on write failure.

◆ print_line

bool(* print_stream_ops::print_line) (struct print_stream *self, int indent, const char *line)

Prints a single line of text at the specified indentation level.

Parameters
selfThe print stream instance.
indentNumber of indentation levels to apply before the line.
lineThe text content to print.
Returns
True on success, false on write failure.

◆ print_line_color

bool(* print_stream_ops::print_line_color) (struct print_stream *self, int indent, const char *line, const color_t *fg, const color_t *bg)

Prints a single line of text with explicit foreground and background colors.

Parameters
selfThe print stream instance.
indentNumber of indentation levels to apply before the line.
lineThe text content to print.
fgForeground color to apply to the line, or NULL for default.
bgBackground color to apply to the line, or NULL for default.
Returns
True on success, false on write failure.

◆ print_preamble

bool(* print_stream_ops::print_preamble) (struct print_stream *self, char *filename, const char *version_string)

Outputs any preamble required by the print format before the first line of content.

Parameters
selfThe print stream instance.
filenameName of the capture file being printed.
version_stringWireshark version string to include in the preamble.
Returns
True on success, false on write failure.

The documentation for this struct was generated from the following file: