[−][src]Struct grok::Matches
The Matches
represent matched results from a Pattern
against text.
Methods
impl<'a> Matches<'a>
[src]
pub fn new(captures: Captures<'a>, names: &'a HashMap<String, u32>) -> Self
[src]
Instantiates the matches for a pattern after the match.
pub fn get(&self, name_or_alias: &str) -> Option<&str>
[src]
Gets the value for the name (or) alias if found, None
otherwise.
pub fn len(&self) -> usize
[src]
Returns the number of matches.
pub fn is_empty(&self) -> bool
[src]
Returns true if there are no matches, false otherwise.
ⓘImportant traits for MatchesIter<'a>pub fn iter(&'a self) -> MatchesIter<'a>
[src]
ⓘImportant traits for MatchesIter<'a>
Returns a tuple of key/value with all the matches found.
Note that if no match is found, the value is empty.
Trait Implementations
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,