Package n10s.utils
Class DateUtils
java.lang.Object
n10s.utils.DateUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic LocalDatestatic LocalDateTimeparseDateTime(String stringDateTime) Convert a String-formatted date into a LocalDateTime object by using LocalDateTime.parse first, and DatatypeConverter.parseDateTime if the first one fails.
-
Constructor Details
-
DateUtils
public DateUtils()
-
-
Method Details
-
parseDateTime
Convert a String-formatted date into a LocalDateTime object by using LocalDateTime.parse first, and DatatypeConverter.parseDateTime if the first one fails.- Parameters:
stringDateTime- The string-formatted date.- Returns:
- LocalDateTime object.
- Throws:
IllegalArgumentException- if the string is not parseable to a date.
-
parseDate
-