[−][src]Enum radix::RadixNum
A number in some radix.
Methods
impl RadixNum
[src]
pub fn from_str(base: &str, radix: usize) -> RadixResult<Self>
[src]
Convert a base
encoded in a certain radix
to a RadixNum
.
pub fn as_str(&self) -> &str
[src]
pub fn with_radix(&self, radix: usize) -> RadixResult<Self>
[src]
Change the radix that self
is encoded with. This does not change
the represented value, but it does change its representation.
pub fn radix(&self) -> usize
[src]
Retrieve the radix that self
is encoded with.
pub fn as_decimal(&self) -> RadixResult<usize>
[src]
pub fn digits<'c>(&'c self) -> impl Iterator<Item = char> + 'c
[src]
Trait Implementations
impl From<usize> for RadixNum
[src]
impl From<u8> for RadixNum
[src]
impl From<u16> for RadixNum
[src]
impl From<u32> for RadixNum
[src]
impl From<u64> for RadixNum
[src]
impl From<u128> for RadixNum
[src]
impl Clone for RadixNum
[src]
impl Eq for RadixNum
[src]
impl Ord for RadixNum
[src]
fn cmp(&self, other: &RadixNum) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
1.21.0[src]
fn clamp(self, min: Self, max: Self) -> Self
[src]
impl PartialEq<RadixNum> for RadixNum
[src]
impl PartialOrd<RadixNum> for RadixNum
[src]
fn partial_cmp(&self, other: &RadixNum) -> Option<Ordering>
[src]
fn lt(&self, other: &RadixNum) -> bool
[src]
fn le(&self, other: &RadixNum) -> bool
[src]
fn gt(&self, other: &RadixNum) -> bool
[src]
fn ge(&self, other: &RadixNum) -> bool
[src]
impl Display for RadixNum
[src]
impl Debug for RadixNum
[src]
impl StructuralPartialEq for RadixNum
[src]
impl StructuralEq for RadixNum
[src]
Auto Trait Implementations
impl Send for RadixNum
impl Sync for RadixNum
impl Unpin for RadixNum
impl UnwindSafe for RadixNum
impl RefUnwindSafe for RadixNum
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> 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, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,