Package io. islandtime. ranges
Date ranges, time intervals, and the ability to iterate over them and perform various operations.
Types
An inclusive range of dates.
An interval between two date-times, assumed to be at the same offset from UTC.
A half-open interval between two instants.
A half-open interval between two offset date-times based on timeline order.
A time point progression builder.
A half-open interval of zoned date-times based on timeline order.
Functions
Converts this interval to an equivalent ZonedDateTimeInterval where both endpoints are given a fixed-offset time zone.
Combines this DateRange with a TimeZone to create a ZonedDateTimeInterval between the start of the first day and the end of the last day in zone.
Combines this DateTimeInterval with a TimeZone to create a ZonedDateTimeInterval where both endpoints are in zone.
Combines this InstantInterval with a TimeZone to create an equivalent ZonedDateTimeInterval where both endpoints are in zone.
Returns a random date within this range using the default random number generator.
Returns a random date within this interval using the default random number generator.
Returns a random date within this interval using the default random number generator. The offset of the start date-time will be used.
Returns a random date within this interval using the default random number generator. The zone of the start date-time will be used.
Returns a random date within this range using the supplied random number generator.
Returns a random date within this interval using the supplied random number generator.
Returns a random date within this interval using the supplied random number generator. The offset of the start date-time will be used.
Returns a random date within this interval using the supplied random number generator. The zone of the start date-time will be used.
Returns a random date within this range using the default random number generator or null if the interval is empty or unbounded.
Returns a random date within this interval using the default random number generator or null if the interval is empty or unbounded.
Returns a random date within this interval using the default random number generator or null if the interval is empty or unbounded. The offset of the start date-time will be used.
Returns a random date within this interval using the default random number generator or null if the interval is empty or unbounded. The zone of the start date-time will be used.
Returns a random date within this range using the supplied random number generator or null if the interval is empty or unbounded.
Returns a random date within this interval using the supplied random number generator or null if the interval is empty or unbounded.
Returns a random date within this interval using the supplied random number generator or null if the interval is empty or unbounded. The offset of the start date-time will be used.
Returns a random date within this interval using the supplied random number generator or null if the interval is empty or unbounded. The zone of the start date-time will be used.
Reverses this progression such that it counts down instead of up, or vice versa.
Creates a progression that steps over the dates in this progression in increments of centuries.
Creates a progression that steps over the dates in this progression in increments of days.
Creates a progression that steps over the dates in this progression in increments of decades.
Creates a progression that steps over the dates in this progression in increments of months.
Creates a progression that steps over the dates in this progression in increments of weeks.
Creates a progression that steps over the dates in this progression in increments of years.
Returns this interval with the precision reduced to just the date.
Converts a string to a DateRange.
Converts a string to a DateRange using a specific parser.
Returns this interval with the precision reduced to only the local date and time.
Converts a string to a DateTimeInterval.
Converts a string to a DateTimeInterval using a specific parser.
Converts this interval to the equivalent DateTimeInterval when both endpoints are in zone.
Converts this interval to the Duration between the start and end date-time, which are assumed to be in the same time zone. In general, it's more appropriate to calculate duration using Instant or ZonedDateTime as any daylight savings rules won't be taken into account when working with DateTime directly.
Converts this interval into a Duration of the same length.
Converts this interval to an InstantInterval.
Converts a string to an InstantInterval.
Converts a string to an InstantInterval using a specific parser.
Converts this range to an InstantInterval between the start of the first day and the end of the last day in zone.
Converts this interval to an InstantInterval where both endpoints are in zone.
Converts this interval to an OffsetDateTimeInterval.
Converts a string to an OffsetDateTimeInterval.
Converts a string to an OffsetDateTimeInterval using a specific parser.
Converts a string to a ZonedDateTimeInterval.
Converts this interval to a ZonedDateTimeInterval using the specified strategy to adjust each endpoint to a valid date, time, and offset in zone.
Converts a string to a ZonedDateTimeInterval using a specific parser.
Creates a DateTimeInterval from this date-time up to, but not including the nanosecond represented by to.
Creates an InstantInterval from this instant up to, but not including to.
Creates an OffsetDateTimeInterval from this date-time up to, but not including to.
Creates a ZonedDateTimeInterval from this date-time up to, but not including to.