pub struct Digit<const B: Base = 10> { /* private fields */ }Expand description
Checks whether the given character is a digit in the specified base B.
Trait Implementations§
Source§impl<const B: Base> Predicate<char> for Digit<B>
impl<const B: Base> Predicate<char> for Digit<B>
Source§type Error = DigitError
type Error = DigitError
The associated error type which is used to represent checks.
Source§fn check(value: &char) -> Result<(), Self::Error>
fn check(value: &char) -> Result<(), Self::Error>
Checks if the value of type
T satisfies the predicate. Read moreSource§fn expect(formatter: &mut Formatter<'_>) -> Result
fn expect(formatter: &mut Formatter<'_>) -> Result
Formats the expectation of the predicate. Read more
Source§fn expect_code(formatter: &mut Formatter<'_>) -> Result
fn expect_code(formatter: &mut Formatter<'_>) -> Result
Formats the expectation code of the predicate. Read more
Source§fn is_satisfied(value: &T) -> bool
fn is_satisfied(value: &T) -> bool
Checks whether the given value satisfies the predicate. Read more
Source§fn expected_code() -> ExpectedCode<T, Self>
fn expected_code() -> ExpectedCode<T, Self>
Returns the expectation code of the predicate.
Auto Trait Implementations§
impl<const B: u32> Freeze for Digit<B>
impl<const B: u32> RefUnwindSafe for Digit<B>
impl<const B: u32> Send for Digit<B>
impl<const B: u32> Sync for Digit<B>
impl<const B: u32> Unpin for Digit<B>
impl<const B: u32> UnwindSafe for Digit<B>
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