Skip to main content

windows

Function windows 

Source
pub fn windows(head: &[u8], tail: &[u8]) -> (Vec<u8>, Vec<u8>)
Expand description

The two windows of a file: the first WINDOW bytes of head and the last WINDOW bytes of the file’s end, starting at a line. tail is the end of a larger file (empty when head holds the whole file); then the part of head behind the first window serves as the end, so the two windows never overlap.