AcSensitiveWordMap

Type Alias AcSensitiveWordMap 

Source
pub type AcSensitiveWordMap = AhoCorasick;

Aliased Type§

pub struct AcSensitiveWordMap { /* private fields */ }

Trait Implementations§

Source§

impl MyTrait for AcSensitiveWordMap

Source§

fn init_ac_dic_from_file(file_path: &str) -> &'static AcSensitiveWordMap

Source§

fn get_ac_dic() -> &'static AcSensitiveWordMap

Source§

fn filter(&self, text: &str) -> String

Source§

fn replace(&self, text: &str, repl: &str) -> String

Source§

fn is_sensitive(&self, text: &str) -> bool

Source§

fn find_one(&self, text: &str) -> String

Source§

fn find_all(&self, text: &str) -> Vec<String>