Documentation
¶
Overview ¶
Package textfmt renders scalar values as the text every streamio output format agrees on: encoding/json's float formatting and ISO-8601 dates and timestamps. It has no dependencies on the record model, so both the record package and the format packages can share it.
Index ¶
Constants ¶
const ( Bits32 = 32 Bits64 = 64 )
Bits32 and Bits64 select the precision AppendFloat formats at.
Variables ¶
This section is empty.
Functions ¶
func AppendDate ¶
AppendDate appends a day count since the Unix epoch to dst as an ISO-8601 calendar date.
func AppendFloat ¶
AppendFloat formats f exactly as encoding/json's floatEncoder does and appends it to dst.
func AppendTimestampMicros ¶
AppendTimestampMicros appends an epoch timestamp in microseconds to dst as an ISO-8601 instant.
func AppendTimestampMillis ¶
AppendTimestampMillis appends an epoch timestamp in milliseconds to dst as an ISO-8601 instant.
func AppendTimestampNanos ¶
AppendTimestampNanos appends an epoch timestamp in nanoseconds to dst as an ISO-8601 instant.
Types ¶
This section is empty.