pub fn segment_into<T: AsRef<[u8]>, E: Extend<Segment>>(
data: T,
max_segment_size: usize,
frame_id: FrameId,
segments: &mut E,
) -> Result<()>Expand description
Helper function to segment data into segments of a given max_segment_size length.
All segments are tagged with the same frame_id and output into the given segments buffer.