Enum sprintf::parser::FormatElement
source · pub enum FormatElement {
Verbatim(String),
Format(ConversionSpecifier),
}Expand description
A part of a format string: either a string of characters to be included verbatim, or a format specifier that should be replaced based on an argument to the vsprintf call.
Variants§
Verbatim(String)
Some characters that are copied to the output as-is
Format(ConversionSpecifier)
A format specifier
Trait Implementations§
source§impl Clone for FormatElement
impl Clone for FormatElement
source§fn clone(&self) -> FormatElement
fn clone(&self) -> FormatElement
Returns a copy 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 FormatElement
impl Debug for FormatElement
source§impl PartialEq for FormatElement
impl PartialEq for FormatElement
source§fn eq(&self, other: &FormatElement) -> bool
fn eq(&self, other: &FormatElement) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl Eq for FormatElement
impl StructuralPartialEq for FormatElement
Auto Trait Implementations§
impl Freeze for FormatElement
impl RefUnwindSafe for FormatElement
impl Send for FormatElement
impl Sync for FormatElement
impl Unpin for FormatElement
impl UnwindSafe for FormatElement
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)