Package com.logicaldoc.util.time
Class DateUtil
- java.lang.Object
-
- com.logicaldoc.util.time.DateUtil
-
public class DateUtil extends Object
Utility methods to handle dates- Since:
- 8.6.1
- Author:
- Marco Meschieri - LogicalDOC
-
-
Constructor Summary
Constructors Constructor Description DateUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
format(Date date)
Formats a date using the ISO formatyyyy-MM-dd HH:mm:ss Z
static String
formatWithMillis(Date date)
Formats a date using the ISO formatyyyy-MM-dd HH:mm:ss.SSS Z
static Date
parse(String formattedDate)
Formats a date using one of the ISO formats.
-
-
-
Method Detail
-
format
public static String format(Date date)
Formats a date using the ISO formatyyyy-MM-dd HH:mm:ss Z
- Parameters:
date
- the date to format- Returns:
- the formatted date
-
formatWithMillis
public static String formatWithMillis(Date date)
Formats a date using the ISO formatyyyy-MM-dd HH:mm:ss.SSS Z
- Parameters:
date
- the date to format- Returns:
- the formatted date
-
-