months Between
Gets the number of whole months between two dates.
Gets the number of whole months between two date-times, assuming they're in the same time zone.
fun monthsBetween(start: OffsetDateTime, endExclusive: OffsetDateTime): IntMonths
Content copied to clipboard
Gets the number of whole months between two date-times, adjusting the offset of endExclusive if necessary to match the starting date-time.
fun monthsBetween(start: ZonedDateTime, endExclusive: ZonedDateTime): IntMonths
Content copied to clipboard
Gets the number of whole months between two zoned date-times, adjusting the time zone of endExclusive if necessary to match the starting date-time.