pub trait AsFancyDuration<T>{
// Required method
fn fancy_duration(&self) -> FancyDuration<T>;
}Expand description
Implement AsFancyDuration for your Duration type, it will annotate those types with the
fancy_duration function which allows trivial and explicit conversion into a fancy duration.
Required Methods§
Sourcefn fancy_duration(&self) -> FancyDuration<T>
fn fancy_duration(&self) -> FancyDuration<T>
Convert T to a fancy_duration, which can be converted to a string representation of the duration.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.