LongYearMonth

Four-digit year / two-digit month (e.g. 2027/12).

Properties

Link copied to clipboard

underlying SimpleDateFormat pattern.

Link copied to clipboard

input mask derived from dateFormat, where each digit is #.

Link copied to clipboard

Functions

Link copied to clipboard
fun convert(text: String, targetFormat: VgsExpiryDateFormat): String?

Reformats text from this format into targetFormat, or null when text cannot be parsed.

Link copied to clipboard
fun format(date: Date?): String?

Formats date using this format, returning null when date is null or invalid.

Link copied to clipboard
fun parse(text: String): Date?

Parses text using this format, returning null when text is invalid.