pub enum ImageRedaction {
Drop,
BoxOut,
Keep,
}Expand description
What happens to embedded images (pictures, page renders) when the pass runs. An image can carry anything the text does — a scanned letter, a screenshot of a profile — and the pass cannot read it without OCR.
Variants§
Drop
Remove every embedded image and page render (the default): nothing unread leaves the document.
BoxOut
OCR each image and paint solid boxes over the lines that carry a
detected span; keep the rest of the pixels. Needs the OCR models (the
docling crate does this; without the models it degrades to Drop
with a warning).
Keep
Leave the images as they are.
Implementations§
Trait Implementations§
Source§impl Clone for ImageRedaction
impl Clone for ImageRedaction
impl Copy for ImageRedaction
Source§impl Debug for ImageRedaction
impl Debug for ImageRedaction
Source§impl Default for ImageRedaction
impl Default for ImageRedaction
impl Eq for ImageRedaction
Source§impl PartialEq for ImageRedaction
impl PartialEq for ImageRedaction
impl StructuralPartialEq for ImageRedaction
Auto Trait Implementations§
impl Freeze for ImageRedaction
impl RefUnwindSafe for ImageRedaction
impl Send for ImageRedaction
impl Sync for ImageRedaction
impl Unpin for ImageRedaction
impl UnsafeUnpin for ImageRedaction
impl UnwindSafe for ImageRedaction
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.