Package net.minidev.asm
Class ConvertDate
java.lang.Object
net.minidev.asm.ConvertDate
Utility class for converting strings into
Date
objects, considering various global date formats.
It handles different month and day names across languages, and supports timezone adjustments.-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Comparator for case-insensitive string comparison. -
Field Summary
-
Constructor Summary
-
Method Summary
-
Field Details
-
defaultTimeZone
Default TimeZone used for date conversions. Can be overwritten to change the default time zone.
-
-
Constructor Details
-
ConvertDate
public ConvertDate()default constructor
-
-
Method Details
-
getMonth
Retrieves the month's integer representation based on the provided month name.- Parameters:
month
- the name of the month- Returns:
- the integer value of the month, or null if the month name is unrecognized
-
convertToDate
try read a Date from a Object- Parameters:
obj
- object to convert to date- Returns:
- a date value
-