Package-level declarations

Types

Link copied to clipboard

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Gives Calendar object from Date

Link copied to clipboard
Link copied to clipboard

get Current Date.

Link copied to clipboard
const val DAY: String
Link copied to clipboard

Gets value of DayOfMonth from Calendar Object

Gets value of DayOfMonth from Date Object

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
const val HOUR: String
Link copied to clipboard

Gets value of Hour from Calendar Object

Gets value of Hour from Date Object

Link copied to clipboard

Gets value of HourOfDay from Calendar Object

Gets value of HourOfDay from Date Object

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
const val MINUTE: String
Link copied to clipboard

Gets value of Minute from Calendar Object

Gets value of Minute from Date Object

Link copied to clipboard

Gets value of Month from Calendar Object

Link copied to clipboard

Gets value of Month from Date Object

Link copied to clipboard
val now: Long

Gets value of Milliseconds of current time

Link copied to clipboard

Gets value of Second from Calendar Object

Gets value of Second from Date Object

Link copied to clipboard
const val TIME_12HOUR: String
Link copied to clipboard
const val TIME_24HOUR: String
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Gets Year directly from Calendar Object

Link copied to clipboard

Gets value of DayOfMonth from Date Object

Functions

Link copied to clipboard
fun addRemMinToHHMM(currentHHMM: String, minutes_to_add: Int?): String

method to provide HH:MM:SS after adding miutes to current HH:MM

Link copied to clipboard

Method to convert 12 hours time hh:mm to 24 hours time

Link copied to clipboard
fun convertDate(date: String, defaultFormat: String, formatWanted: String): String

Method to convert one date format to another format

Link copied to clipboard
fun Date.convertTo(format: String): String?
Link copied to clipboard
fun Date.day(): Int
Link copied to clipboard
Link copied to clipboard
fun Date.dayOfWeekName(locale: Locale = Locale.getDefault()): String?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun extractHours(millis: Long): Long
Link copied to clipboard
fun extractMinutes(millis: Long): Long
Link copied to clipboard
fun extractSeconds(millis: Long): Long
Link copied to clipboard
fun Date.format(pattern: String, locale: Locale): String
Link copied to clipboard

Formats date according to device's default date format

Link copied to clipboard

Formats time according to device's default time format

Link copied to clipboard
Link copied to clipboard

return current time 24 hour format

Link copied to clipboard
fun Date.getAge(): Int
Link copied to clipboard
fun getCurDate(format: String): String

Method to get Current Date

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Gets current time in given format

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun getDateDifferense(startDate: Date, endDate: Date): Pair<String, Long>?
Link copied to clipboard
fun getDateTimeFromMillis(millis: Long, dateFormat: String): String

Method to get Date time from millis, You can use System.currentTimeMillis()

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun getDifference(startTime: Long, endTime: Long, rTimeConst: String): Long

method to get minutes from start and end time

Link copied to clipboard
fun getDifferenceHHmmSS(startTime: Long, endTime: Long, formatSpecifier: String): String

method to get minutes from start and end time

Link copied to clipboard
fun Date.getDifferenceInDays(compareDate: Date): Long
Link copied to clipboard
fun getDifferenceInMin(startTime: Long, endTime: Long): Int

method to get minutes from start and end time

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun getFormattedTime(format: String, millis: Int): String

Method to get String date from millis

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Method to get long millis from hhmmss

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun getMinFromMillis(millis: Long): Long
Link copied to clipboard
fun getMinFromSeconds(seconds: Long): Long
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun getSecFromMillis(millis: Long): Long
Link copied to clipboard
Link copied to clipboard
fun getTimeFromMillis(date_time_millisecond: String, dateFormat: String): String

method to get date and time

Link copied to clipboard
fun Date.hour(): Int
Link copied to clipboard
Link copied to clipboard
fun Date.isDateSameDay(compareDate: Date): Boolean
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Date.minute(): Int
Link copied to clipboard
Link copied to clipboard
fun Date.month(): Int
Link copied to clipboard
fun Date.monthName(locale: Locale = Locale.getDefault()): String?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Date.second(): Int
Link copied to clipboard
Link copied to clipboard
fun timeAsMillis(hours: Int, minutes: Int, seconds: Int): Long
Link copied to clipboard
Link copied to clipboard
fun Date.today(): Date
Link copied to clipboard
Link copied to clipboard
@RequiresApi(value = 26)
fun Instant.toOffsetDateTime(zone: ZoneId = ZoneId.systemDefault()): OffsetDateTime

Obtains an OffsetDateTime instance from Instant

Link copied to clipboard
fun Date.toString(format: String): String
Link copied to clipboard
Link copied to clipboard
fun Date.with(weekday: Int = -1): Date
fun Date.with(year: Int = -1, month: Int = -1, day: Int = -1, hour: Int = -1, minute: Int = -1, second: Int = -1, millisecond: Int = -1): Date
Link copied to clipboard
fun Date.year(): Int
Link copied to clipboard
Link copied to clipboard