pub struct TermDisplay { /* private fields */ }
Implementations§
Source§impl TermDisplay
impl TermDisplay
pub const fn empty() -> Self
pub fn new( matcher: Matcher, formatter: Formatter, ) -> Result<Self, ConversionError>
pub fn deparse_string(&self) -> (String, String)
pub fn is_empty(&self) -> bool
Sourcepub const fn as_match_no_capture<'a>(
&self,
haystack: &'a str,
) -> MatchResult<'a, '_>
pub const fn as_match_no_capture<'a>( &self, haystack: &'a str, ) -> MatchResult<'a, '_>
Call this when you already know that self.matcher
matches haystack
.
Sourcepub fn as_match_capture<'a>(&self, haystack: &'a str) -> MatchResult<'a, '_>
pub fn as_match_capture<'a>(&self, haystack: &'a str) -> MatchResult<'a, '_>
Call this when you already know that self.matcher
matches haystack
.
Trait Implementations§
Source§impl Clone for TermDisplay
impl Clone for TermDisplay
Source§fn clone(&self) -> TermDisplay
fn clone(&self) -> TermDisplay
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for TermDisplay
impl Debug for TermDisplay
Source§impl FromIterator<TermDisplay> for Result<TermDisplayContext, TdcError>
impl FromIterator<TermDisplay> for Result<TermDisplayContext, TdcError>
Source§fn from_iter<T: IntoIterator<Item = TermDisplay>>(iter: T) -> Self
fn from_iter<T: IntoIterator<Item = TermDisplay>>(iter: T) -> Self
Creates a value from an iterator. Read more
Source§impl PartialEq for TermDisplay
impl PartialEq for TermDisplay
Source§impl TryFrom<TermDisplayConst<'_>> for TermDisplay
impl TryFrom<TermDisplayConst<'_>> for TermDisplay
Source§type Error = ConversionError
type Error = ConversionError
The type returned in the event of a conversion error.
impl Eq for TermDisplay
impl StructuralPartialEq for TermDisplay
Auto Trait Implementations§
impl Freeze for TermDisplay
impl RefUnwindSafe for TermDisplay
impl Send for TermDisplay
impl Sync for TermDisplay
impl Unpin for TermDisplay
impl UnwindSafe for TermDisplay
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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