DateUtils

object DateUtils

Date/time utilities

Before this object is accessed the first time, the accessing thread's contextClassLoader must be set to an Android Context.classLoader!

Functions

Link copied to clipboard

Find the best matching Android (= available in system and Java timezone registry) time zone ID for a given arbitrary time zone ID:

Link copied to clipboard
fun getZoneId(id: String?): ZoneId?

Gets a ZoneId from a given ID string. In opposite to ZoneId.of, this methods returns null when the zone is not available.

Link copied to clipboard

Loads a time zone from the ical4j time zone registry (which contains the VTIMEZONE definitions).

Link copied to clipboard
fun isDate(date: DateProperty?): Boolean

Determines whether a given date represents a DATE value.

Link copied to clipboard
fun isDateTime(date: DateProperty?): Boolean

Determines whether a given date represents a DATE-TIME value.

Link copied to clipboard

Parses a VTIMEZONE definition to a VTimeZone object.