rrva
06/25/2020, 7:11 AM@OptIn(ExperimentalTime::class)
class DateTimeSource(val time: OffsetDateTime) : AbstractLongTimeSource(unit = DurationUnit.MILLISECONDS), TimeSource {
override fun read(): Long {
return time.toInstant().toEpochMilli()
}
}
ilya.gorbunov
06/25/2020, 7:38 PMilya.gorbunov
06/25/2020, 8:18 PMTimeSource
like this: https://kotlinlang.slack.com/archives/C0922A726/p1588869705496300?thread_ts=1588865356.494000&cid=C0922A726ilya.gorbunov
06/25/2020, 8:19 PMmarkAt(OffsetDateTime)
method to get a TimeMark
corresponding to that date/time value value.rrva
06/26/2020, 6:58 AM