pub fn fast_format_hex<const N: usize>(
bytes: &[u8],
group: usize,
max_lines: Option<usize>,
) -> FixedStr<N>
Expand description
Formats the given byte slice as an uppercase hexadecimal string,
grouping bytes as specified and inserting spaces and newlines accordingly,
then returns a FixedStr
containing the formatted output.
Any unused space in the output buffer is zero‑padded.
§Parameters
bytes
: The input byte slice to format.group
: The number of bytes per group. A newline is inserted when a group is complete.max_lines
: An optional limit to the number of output lines. IfNone
, all groups are printed.
§Returns
A FixedStr
containing the hex‑formatted representation of bytes
.
§Panics
Panics if group == 0
.