Struct std::path::Display1.0.0[][src]

pub struct Display<'a> { /* fields omitted */ }

Helper struct for safely printing paths with format! and {}.

A Path might contain non-Unicode data. This struct implements the Display trait in a way that mitigates that. It is created by the display method on Path.


use std::path::Path;

let path = Path::new("/tmp/");

println!("{}", path.display());

Trait Implementations

impl Debug for Display<'_>[src]

impl Display for Display<'_>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for Display<'a>[src]

impl<'a> Send for Display<'a>[src]

impl<'a> Sync for Display<'a>[src]

impl<'a> Unpin for Display<'a>[src]

impl<'a> UnwindSafe for Display<'a>[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T> ToString for T where
    T: Display + ?Sized

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.