method ZonedTime.fmt
Formats with a pattern (dd.MM.yyyy HH:mm XXX VV); an empty pattern is ISO 8601 with offset and [zone].
Example:
use std.time { Time }
fn main() io {
print(Time.ofUnixSeconds(0).in(tz"Asia/Tokyo").fmt("dd.MM.yyyy HH:mm XXX"))
}Output
01.01.1970 09:00 +09:00
pub(api) fn fmt(pattern: str) -> strComplexity. O(len(pattern)).
Since. 1.0.0-beta
Parameters
| Name | Type |
|---|---|
pattern | str |
Returns
str
Effects
none declared (pure unless the body says otherwise)
Defined in: std/time/time.oxl:2344