pub trait ProcessCapability: Send + Sync {
// Required methods
fn id(&self) -> &str;
fn process(&self, raw: &mut RawDoc) -> Result<(), DocError>;
// Provided methods
fn is_available(&self) -> bool { ... }
fn should_apply(&self, _raw: &RawDoc) -> bool { ... }
}Expand description
处理能力:全局共享,就地增强 RawDoc(OCR / layout)。
Required Methods§
Provided Methods§
fn is_available(&self) -> bool
fn should_apply(&self, _raw: &RawDoc) -> bool
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".