Trait MatchPattern

Source
pub trait MatchPattern {
    type MatchResult;

    // Required method
    fn perform_match(&self, haystack: &[u8]) -> Option<Self::MatchResult>;
}
Expand description

Indicating types that can be used for wait_for_line matching.

Required Associated Types§

Required Methods§

Source

fn perform_match(&self, haystack: &[u8]) -> Option<Self::MatchResult>

Implementations on Foreign Types§

Source§

impl MatchPattern for str

Source§

type MatchResult = ()

Source§

fn perform_match(&self, haystack: &[u8]) -> Option<Self::MatchResult>

Source§

impl MatchPattern for Regex

Source§

type MatchResult = Vec<Vec<u8>>

Source§

fn perform_match(&self, haystack: &[u8]) -> Option<Self::MatchResult>

Source§

impl MatchPattern for Regex

Source§

type MatchResult = Vec<String>

Source§

fn perform_match(&self, haystack: &[u8]) -> Option<Self::MatchResult>

Source§

impl MatchPattern for [u8]

Source§

type MatchResult = ()

Source§

fn perform_match(&self, haystack: &[u8]) -> Option<Self::MatchResult>

Source§

impl<T: MatchPattern + ?Sized> MatchPattern for &T

Implementors§