Skip to main content

document_format

Function document_format 

Source
pub fn document_format(bytes: &[u8]) -> Option<DocumentFormat>
Expand description

The document format bytes hold: a recording by its header, a PDF by its %PDF- header, an Office or OpenDocument package by the parts and media type its zip holds, RTF, or an HTML page. None for plain text, Markdown and anything else, whose name is all that says what it is.