I'm looking for something like TimeRange. In fact I thought TimeRange was just the thing I needed: A Range/Interval object that models the span between a start Instant and an end Instant. Then, I discovered that it's part of the android-wearable stuff? And not part of the core stuff or even stock android stuff? Is there an alternative that can be used on a normal Android phone project?
e
ephemient
04/17/2023, 9:14 PM
why not
ClosedRange<Instant>
using built-in types?
(or
OpenEndRange<Instant>
if that's what you want)
t
Travis Griggs
04/17/2023, 10:00 PM
That's excellent. Wouldn't have thought to. Not sure I knew you could use those without discrete steps. But since I apparently can... why then is there a TimeRange in the wearable stuff? Why don't they just used XRange<Instant> ?
e
ephemient
04/17/2023, 10:22 PM
ComplicationData predates androidx-wear migrating to Kotlin, and it's probably still nice for Java consumers