Duration

@JsonClass(generateAdapter = true)
data class Duration(@Json(name = "startTimestamp") val startTimestamp: ZonedDateTime, @Json(name = "endTimestamp") val endTimestamp: ZonedDateTime)

Represents a duration of time defined by a start timestamp and an end timestamp. Example:

{
"startTimestamp": "2022-02-02T10:41:08.315Z",
"endTimestamp": "2022-02-02T10:45:09.962Z"
}

Constructors

Link copied to clipboard
constructor(@Json(name = "startTimestamp") startTimestamp: ZonedDateTime, @Json(name = "endTimestamp") endTimestamp: ZonedDateTime)

Properties

Link copied to clipboard

End timestamp of the duration. Example: "2022-02-02T10:45:09.962Z"

Link copied to clipboard

Start timestamp of the duration. Example: "2022-02-02T10:41:08.315Z"