日期格式:YYYY-MM-DDTHH:mm:ss.sssZ
解析:
LocalDateTime.parse(日期字符串, DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss"));
以下内容引用自:https://262.ecma-international.org/6.0/#sec-date-time-string-format
20.3.1.16Date Time String Format
ECMAScript defines a string interchange format for date-times based upon a simplification of the ISO 8601 Extended Format. The format is as follows: YYYY-MM-DDTHH:mm:ss.sssZ
Where the fields are as follows:
YYYY | is the decimal digits of the year 0000 to 9999 in the Gregorian calendar. |
- | "-" (hyphen) appears literally twice in the string. |
MM | is the month of the year from 01 (January) to 12 (December). |
DD | is the day of the month from 01 to 31. |
T | "T" appears literally in the string, to indicate the beginning of the time element. |
HH | is the number of complete hours that have passed since midnight as two decimal digits from 00 to 24. |
: | ":" (colon) appears literally twice in the string. |
mm | is the number of complete minutes since the start of the hour as two decimal digits from 00 to 59. |
ss | is the number of complete seconds since the start of the minute as two decimal digits from 00 to 59. |
. | "." (dot) appears literally in the string. |
sss | is the number of complete milliseconds since the start of the second as three decimal digits. |
Z | is the time zone offset specified as "Z" (for UTC) or either "+" or "-" followed by a time expression HH:mm |