Struct custom_format::compile_time::CustomFormatter
source · [−]pub struct CustomFormatter<'a, T, const SPEC: u128> { /* private fields */ }
Available on crate feature
compile-time
only.Expand description
Wrapper for custom formatting via its Display
trait.
The format specifier is a const-generic parameter and is part of the type.
Implementations
sourceimpl<'a, T, const SPEC: u128> CustomFormatter<'a, T, SPEC>
impl<'a, T, const SPEC: u128> CustomFormatter<'a, T, SPEC>
sourcepub fn new(value: &'a T) -> Self
pub fn new(value: &'a T) -> Self
Construct a new CustomFormatter
value
Trait Implementations
sourceimpl<'a, T: Clone, const SPEC: u128> Clone for CustomFormatter<'a, T, SPEC>
impl<'a, T: Clone, const SPEC: u128> Clone for CustomFormatter<'a, T, SPEC>
sourcefn clone(&self) -> CustomFormatter<'a, T, SPEC>
fn clone(&self) -> CustomFormatter<'a, T, SPEC>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<'a, T: Debug, const SPEC: u128> Debug for CustomFormatter<'a, T, SPEC>
impl<'a, T: Debug, const SPEC: u128> Debug for CustomFormatter<'a, T, SPEC>
sourceimpl<T: CustomFormat<SPEC>, const SPEC: u128> Display for CustomFormatter<'_, T, SPEC>
impl<T: CustomFormat<SPEC>, const SPEC: u128> Display for CustomFormatter<'_, T, SPEC>
Auto Trait Implementations
impl<'a, T, const SPEC: u128> RefUnwindSafe for CustomFormatter<'a, T, SPEC> where
T: RefUnwindSafe,
impl<'a, T, const SPEC: u128> Send for CustomFormatter<'a, T, SPEC> where
T: Sync,
impl<'a, T, const SPEC: u128> Sync for CustomFormatter<'a, T, SPEC> where
T: Sync,
impl<'a, T, const SPEC: u128> Unpin for CustomFormatter<'a, T, SPEC>
impl<'a, T, const SPEC: u128> UnwindSafe for CustomFormatter<'a, T, SPEC> where
T: RefUnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more