pub enum ParseInput {
Path(PathBuf),
Bytes(Vec<u8>),
}Expand description
A document source: either a file path or raw bytes.
Mirrors LiteParseInput in the TypeScript codebase.
Variants§
Path(PathBuf)
Path to a file on disk.
Bytes(Vec<u8>)
In-memory bytes. PDFs go straight to the parser with zero disk I/O; non-PDF bytes are written to a temp file for format conversion.
Trait Implementations§
Source§impl Clone for ParseInput
impl Clone for ParseInput
Source§fn clone(&self) -> ParseInput
fn clone(&self) -> ParseInput
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ParseInput
impl Debug for ParseInput
Source§impl From<&Path> for ParseInput
impl From<&Path> for ParseInput
Source§impl From<&str> for ParseInput
impl From<&str> for ParseInput
Source§impl From<PathBuf> for ParseInput
impl From<PathBuf> for ParseInput
Source§impl From<String> for ParseInput
impl From<String> for ParseInput
Auto Trait Implementations§
impl Freeze for ParseInput
impl RefUnwindSafe for ParseInput
impl Send for ParseInput
impl Sync for ParseInput
impl Unpin for ParseInput
impl UnsafeUnpin for ParseInput
impl UnwindSafe for ParseInput
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