Skip to main content
← rust.krizaka.comkrizaka.com

preview

Function preview 

Source
pub fn preview(
    file: &ScopedPath,
    limits: &Limits,
) -> Result<Preview, FilesError>
Expand description

Previews a file already resolved through the scope.

A bare path is refused at compile time: only the scope makes the path a preview reads.

ⓘ
let _ = krizaka_rust::files::preview(std::path::Path::new("/etc/hosts"), &Default::default());