OfficeDocumentHandler

Trait OfficeDocumentHandler 

Source
pub trait OfficeDocumentHandler {
    // Provided methods
    fn extract_from_zip(
        &self,
        data: &[u8],
        main_xml_path: &str,
    ) -> Result<String> { ... }
    fn extract_text_from_xml(&self, xml: &str) -> Result<String> { ... }
    fn extract_metadata_from_zip(&self, data: &[u8]) -> HashMap<String, String> { ... }
}
Expand description

Base handler for Office documents (DOCX, PPTX, XLSX)

Provided Methods§

Source

fn extract_from_zip(&self, data: &[u8], main_xml_path: &str) -> Result<String>

Source

fn extract_text_from_xml(&self, xml: &str) -> Result<String>

Source

fn extract_metadata_from_zip(&self, data: &[u8]) -> HashMap<String, String>

Implementors§

Source§

impl OfficeDocumentHandler for DocxHandler

Available on crate feature content-processing only.
Source§

impl OfficeDocumentHandler for PptxHandler

Available on crate feature content-processing only.
Source§

impl OfficeDocumentHandler for XlsxHandler

Available on crate feature content-processing only.