formatTimestampInto

fnchar[] formatTimestampInto(long epochNanos, return char[] buf) @safe pure nothrow

Formats a timestamp into buf exactly like Timestamp.toString: YYYY-MM-DDTHH:MM:SS[.f{1,9}]Z, the fraction omitted when zero and trailing zeros trimmed otherwise. Allocation-free; calendar arithmetic is days-from-civil, so pre-1970 epochs need no SysTime.

Parameters

epochNanosnanoseconds since the Unix epoch
bufcaller-provided storage (at least 30 bytes)

Returns

the written slice of buf.