我正在try 在Java中解析"093000",如下所示:
LocalTime parsed = LocalTime.parse("093000", DateTimeFormatter.ofPattern("hhmmss"));
然而,我遇到了这个异常,似乎无法弄清楚它
Exception in thread "main" java.time.format.DateTimeParseException: Text '093000' could not be parsed: Unable to obtain LocalTime from TemporalAccessor: {MinuteOfHour=30, HourOfAmPm=9, SecondOfMinute=0, MicroOfSecond=0, MilliOfSecond=0, NanoOfSecond=0},ISO of type java.time.format.Parsed
at java.base/java.time.format.DateTimeFormatter.createError(DateTimeFormatter.java:2023)
这与AM/PM有关吗?