Returns the date in the default time zone, constructed from the given components (year, month, day, etc.).
Name |
Type of value |
Description |
year |
int |
The year. |
month |
int |
The number of month (0-based. e.g., 0 for January) You can use the following constants as a value: JANUARY FEBRUARY MARCH APRIL MAY JUNE JULY AUGUST SEPTEMBER OCTOBER NOVEMBER DECEMBER |
day |
int |
The day of the month. |
hourOfDay |
int |
The hour of day (using 24-hour clock). |
minute |
int |
The minute. |
second |
int |
The second. |
Type |
Description |
java.util.Date |
The date in the default time zone, constructed from the given components (year, month, day, etc.). |
Returns the date in the default time zone with the given field values and the time set to midnight.
Name |
Type of value |
Description |
year |
int |
The year. |
month |
int |
The number of month (0-based. e.g., 0 for January) You can use the following constants as a value: JANUARY FEBRUARY MARCH APRIL MAY JUNE JULY AUGUST SEPTEMBER OCTOBER NOVEMBER DECEMBER |
day |
int |
The day of the month. |
Type |
Description |
java.util.Date |
The date in the default time zone, constructed from the given components (year, month, day). |
Parses the date from the given string using the date format pattern. Throws an error if the format is wrong or the text cannot be parsed.
Name |
Type of value |
Description |
dateFormat |
String |
The date format pattern, e.g. "MM/dd/yyyy HH:ss". |
text |
String |
The text to be parsed as date. |
Type |
Description |
java.util.Date |
The successfully parsed date. |