pub fn serialize<T, S>(d: &T, s: S) -> Result<S::Ok, S::Error>where for<'a> Serde<&'a T>: Serialize, S: Serializer,
Serializes a Duration or SystemTime via the humantime crate.
Duration
SystemTime
This function can be used with serde_derive’s with and serialize_with annotations.
serde_derive
with
serialize_with