Struct regex::Match [−][src]
Match represents a single match of a regex in a haystack.
The lifetime parameter 't
refers to the lifetime of the matched text.
Methods
impl<'t> Match<'t>
[src]
[−]
impl<'t> Match<'t>
pub fn start(&self) -> usize
[src]
[−]
pub fn start(&self) -> usize
Returns the starting byte offset of the match in the haystack.
pub fn end(&self) -> usize
[src]
[−]
pub fn end(&self) -> usize
Returns the ending byte offset of the match in the haystack.
pub fn as_str(&self) -> &'t str
[src]
[−]
pub fn as_str(&self) -> &'t str
Returns the matched text.
Trait Implementations
impl<'t> Copy for Match<'t>
[src]
impl<'t> Copy for Match<'t>
impl<'t> Clone for Match<'t>
[src]
[+]
impl<'t> Clone for Match<'t>
impl<'t> Debug for Match<'t>
[src]
[+]
impl<'t> Debug for Match<'t>
impl<'t> Eq for Match<'t>
[src]
impl<'t> Eq for Match<'t>
impl<'t> PartialEq for Match<'t>
[src]
[+]
impl<'t> PartialEq for Match<'t>
impl<'t> From<Match<'t>> for &'t str
[src]
[+]
impl<'t> From<Match<'t>> for &'t str