Package-level declarations

Contains serializers for time-related types, such as java.time.Instant.

Types

Link copied to clipboard
object InstantAsLongSerializer : KSerializer<Instant>

Serializes an Instant to its' epoch millis. ⚠️ Nanosecond precision is lost when encoding/decoding Instants with this serializer

Link copied to clipboard
object InstantAsStringSerializer : KSerializer<Instant>
Link copied to clipboard
object LocalDateAsStringSerializer : KSerializer<LocalDate>

Uses ISO8601 format Example: 2020-01-01

Link copied to clipboard

Uses ISO8601 format, with no timezone information Example: 2020-01-01T18:49:00

Link copied to clipboard
object LocalTimeAsStringSerializer : KSerializer<LocalTime>

Uses ISO8601 format, with no timezone information Example: 12:00:00 means 12 'o clock at noon.

Link copied to clipboard

Serializes an OffsetDateTime to a string, including offset. Example: 2020-01-01T18:49:00+01:00

Link copied to clipboard
object YearAsIntSerializer : KSerializer<Year>

Serializes a Year to an integer. Example: 2020

Link copied to clipboard
object YearAsStringSerializer : KSerializer<Year>

Serializes a Year to a string. Example: "2020"

Link copied to clipboard
object YearMonthAsStringSerializer : KSerializer<YearMonth>

Serializes a YearMonth to a string. Example: 2020-01