pub struct DocumentParser { /* private fields */ }Expand description
Document parser for multi-modal content
Implementations§
Source§impl DocumentParser
impl DocumentParser
Sourcepub fn new(
config: DocumentParserConfig,
image_processor: Box<dyn ImageProcessor>,
table_processor: Box<dyn TableProcessor>,
chart_processor: Box<dyn ChartProcessor>,
) -> RragResult<Self>
pub fn new( config: DocumentParserConfig, image_processor: Box<dyn ImageProcessor>, table_processor: Box<dyn TableProcessor>, chart_processor: Box<dyn ChartProcessor>, ) -> RragResult<Self>
Create new document parser
Sourcepub async fn parse_document(
&self,
file_path: &Path,
) -> RragResult<DocumentParseResult>
pub async fn parse_document( &self, file_path: &Path, ) -> RragResult<DocumentParseResult>
Parse document from file
Auto Trait Implementations§
impl Freeze for DocumentParser
impl !RefUnwindSafe for DocumentParser
impl Send for DocumentParser
impl Sync for DocumentParser
impl Unpin for DocumentParser
impl !UnwindSafe for DocumentParser
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more