我有这段代码:
public static final String DATE_PATTERN = "yyyy-MM-dd";
OffsetDateTime.parse(startTime, DateTimeFormatter.ofPattern(DateFormat.DATE_PATTERN)
但是解析时出现此错误:
java.time.format.DateTimeParseException: Text '2019-07-10' could not be parsed: Unable to obtain OffsetDateTime from TemporalAccessor: {},ISO resolved to 2019-07-10 of type java.time.format.Parsed