pub struct ShellNounDetector { /* private fields */ }Expand description
Simple pattern-based shell noun detector.
Implementations§
Source§impl ShellNounDetector
impl ShellNounDetector
Sourcepub fn detect(&self, text: &str) -> Vec<ShellNounInstance>
pub fn detect(&self, text: &str) -> Vec<ShellNounInstance>
Detect shell nouns in text.
Looks for patterns like “this [shell noun]”, “the [shell noun] that”, etc.
Sourcepub fn is_shell_noun(&self, word: &str) -> bool
pub fn is_shell_noun(&self, word: &str) -> bool
Check if a word is a shell noun.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ShellNounDetector
impl RefUnwindSafe for ShellNounDetector
impl Send for ShellNounDetector
impl Sync for ShellNounDetector
impl Unpin for ShellNounDetector
impl UnsafeUnpin for ShellNounDetector
impl UnwindSafe for ShellNounDetector
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
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more