Initial Commit only include kotlinx.datetime utils, others will follow.
NOTEs:
- use .toEpochMilliseconds() to convert to Long values
- ALWAYS store dates un UCT
- for this demo I used
pastXDaysUtc(days = 5).toEpochMilliseconds().relativeTimeSpanUtc()to get a Long TimeDate value - for this demo I used
now()(kotlinx.datetime.Clock.System.now) for Instant
Instant.dateTimePeriod()=PT0.000324000SnowToLongSystemDefault()=1700058378780currentMoment()=2023-11-15T14:26:18.780031ZgetCurrentTimeInSeconds()=1700058378currentDayFormatted()=2023 NOVEMBER 15currentMomentUtc()=2023-11-15T14:26:18.780062ZnowToLongUtc()=1700058378780nextMonthUtc()=2023-12-01T00:00:00ZfirstDayUtc()=2023-11-01T00:00:00ZlastDayUtc()=2023-11-30T00:00:00ZdateInUtc()=2023-11-15in30DaysUtc()=2023-12-15T14:26:18.780031ZinXDaysUtc(days = 20)=2023-12-05T14:26:18.780031Zpast15DaysUtc()=2023-10-31T14:26:18.780031Zpast60DaysUtc()=2023-09-16T14:26:18.780031ZpastXDaysUtc(days = 20)=2023-10-26T14:26:18.780031ZLong.relativeTimeSpanUtc()= 5 days ago
P.S. Request more Utilities if you need.