pub trait ContentProcessor: Send + Sync {
// Required methods
fn can_process(
&self,
extractor_type: ExtractorType,
raw_text: &str,
config: &ParserConfig,
) -> bool;
fn process(&self, raw_text: &str, config: &ParserConfig) -> Result<String>;
}Expand description
Content preprocessor hook.
Required Methods§
Sourcefn can_process(
&self,
extractor_type: ExtractorType,
raw_text: &str,
config: &ParserConfig,
) -> bool
fn can_process( &self, extractor_type: ExtractorType, raw_text: &str, config: &ParserConfig, ) -> bool
Returns whether this processor should run.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".