[−][src]Struct dyn_fmt::Arguments
This structure represents a format string combined with its arguments.
In contrast with fmt::Arguments
this structure can be easily and safely created at runtime.
Implementations
impl<'a, F: AsRef<str>, T: Display + ?Sized + 'a, I: IntoIterator<Item = &'a T> + Clone> Arguments<'a, F, T, I>
[src]
pub fn new(fmt: F, args: I) -> Self
[src]
Creates a new instance of a Display
able structure, representing formatted arguments.
A runtime analog of format_args!
macro.
Extra arguments are ignored, missing arguments are replaced by empty string.
Examples:
dyn_fmt::Arguments::new("{}a{}b{}c", &[1, 2, 3]); // "1a2b3c" dyn_fmt::Arguments::new("{}a{}b{}c", &[1, 2, 3, 4]); // "1a2b3c" dyn_fmt::Arguments::new("{}a{}b{}c", &[1, 2]); // "1a2bc" dyn_fmt::Arguments::new("{{}}{}", &[1, 2]); // "{}1"
Trait Implementations
impl<'a, F: Clone + AsRef<str>, T: Clone + Display + ?Sized + 'a, I: Clone + IntoIterator<Item = &'a T>> Clone for Arguments<'a, F, T, I>
[src]
impl<'a, F: Debug + AsRef<str>, T: Debug + Display + ?Sized + 'a, I: Debug + IntoIterator<Item = &'a T> + Clone> Debug for Arguments<'a, F, T, I>
[src]
impl<'a, F: AsRef<str>, T: Display + ?Sized + 'a, I: IntoIterator<Item = &'a T> + Clone> Display for Arguments<'a, F, T, I>
[src]
Auto Trait Implementations
impl<'a, F, T: ?Sized, I> RefUnwindSafe for Arguments<'a, F, T, I> where
F: RefUnwindSafe,
I: RefUnwindSafe,
F: RefUnwindSafe,
I: RefUnwindSafe,
impl<'a, F, T: ?Sized, I> Send for Arguments<'a, F, T, I> where
F: Send,
I: Send,
F: Send,
I: Send,
impl<'a, F, T: ?Sized, I> Sync for Arguments<'a, F, T, I> where
F: Sync,
I: Sync,
F: Sync,
I: Sync,
impl<'a, F, T: ?Sized, I> Unpin for Arguments<'a, F, T, I> where
F: Unpin,
I: Unpin,
F: Unpin,
I: Unpin,
impl<'a, F, T: ?Sized, I> UnwindSafe for Arguments<'a, F, T, I> where
F: UnwindSafe,
I: UnwindSafe,
F: UnwindSafe,
I: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
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> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
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>,