pub struct CharacterValidator;
Expand description
The CharacterValidator
structure defines static methods for character
validation.
Implementations§
Source§impl CharacterValidator
impl CharacterValidator
Sourcepub fn indent_count(string: &str) -> usize
pub fn indent_count(string: &str) -> usize
Returns the count of indentation characters in a string.
pub fn is_whitespace(ch: char) -> bool
pub fn is_line_terminator(ch: char) -> bool
pub fn is_bin_digit(ch: char) -> bool
pub fn is_dec_digit(ch: char) -> bool
pub fn is_hex_digit(ch: char) -> bool
Sourcepub fn hex_digit_mv(ch: char) -> Option<u32>
pub fn hex_digit_mv(ch: char) -> Option<u32>
Returns the mathematical value of a hexadecimal digit.
Sourcepub fn bin_digit_mv(ch: char) -> Option<u32>
pub fn bin_digit_mv(ch: char) -> Option<u32>
Returns the mathematical value of a binary digit.
pub fn is_css_identifier_start(ch: char) -> bool
pub fn is_css_identifier_part(ch: char) -> bool
pub fn is_identifier_start(ch: char) -> bool
pub fn is_identifier_part(ch: char) -> bool
pub fn is_xml_name_start(ch: char) -> bool
pub fn is_xml_name_part(ch: char) -> bool
pub fn is_xml_whitespace(ch: char) -> bool
Auto Trait Implementations§
impl Freeze for CharacterValidator
impl RefUnwindSafe for CharacterValidator
impl Send for CharacterValidator
impl Sync for CharacterValidator
impl Unpin for CharacterValidator
impl UnwindSafe for CharacterValidator
Blanket Implementations§
Source§impl<Src, Scheme> ApproxFrom<Src, Scheme> for Srcwhere
Scheme: ApproxScheme,
impl<Src, Scheme> ApproxFrom<Src, Scheme> for Srcwhere
Scheme: ApproxScheme,
Source§fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
Convert the given value into an approximately equivalent representation.
Source§impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Srcwhere
Dst: ApproxFrom<Src, Scheme>,
Scheme: ApproxScheme,
impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Srcwhere
Dst: ApproxFrom<Src, Scheme>,
Scheme: ApproxScheme,
Source§type Err = <Dst as ApproxFrom<Src, Scheme>>::Err
type Err = <Dst as ApproxFrom<Src, Scheme>>::Err
The error type produced by a failed conversion.
Source§fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
Convert the subject into an approximately equivalent representation.
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, Dst> ConvAsUtil<Dst> for T
impl<T, Dst> ConvAsUtil<Dst> for T
Source§impl<T> ConvUtil for T
impl<T> ConvUtil for T
Source§fn approx_as<Dst>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst>,
fn approx_as<Dst>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst>,
Approximate the subject to a given type with the default scheme.
Source§fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err>
fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err>
Approximate the subject to a given type with a specific scheme.