Struct ruplicity::time_utils::PrettyDisplay
source · pub struct PrettyDisplay(_);
Expand description
Implements Display
in a pretty style for some Tm instance.
The format is month day year
in case the timestamp is for a year different than the current;
it is month day time
otherwise.
Example
Suppose to have the timestamp 2012-02-22T14:53:18Z
. If we are in 2012, the display will be
Feb 22 14:53
; if we are in 2015, the display will be Feb 22 2012
.
Trait Implementations§
source§impl Clone for PrettyDisplay
impl Clone for PrettyDisplay
source§fn clone(&self) -> PrettyDisplay
fn clone(&self) -> PrettyDisplay
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 PrettyDisplay
impl Debug for PrettyDisplay
source§impl Display for PrettyDisplay
impl Display for PrettyDisplay
impl Copy for PrettyDisplay
Auto Trait Implementations§
impl RefUnwindSafe for PrettyDisplay
impl Send for PrettyDisplay
impl Sync for PrettyDisplay
impl Unpin for PrettyDisplay
impl UnwindSafe for PrettyDisplay
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