gpt4 book ai didi

java - SimpleDateFormat 的格式化语法是 Java 发明的吗?

转载 作者:塔克拉玛干 更新时间:2023-11-03 02:59:07 25 4
gpt4 key购买 nike

是Java的SimpleDateFormat中定义的日期-时间格式字符串的语法类(如 "EEE, MMM d, ''yy" 等)原始 Java 发明,还是基于其他一些语法定义,如 ICU'sCLDR's ?!

有人知道将 SimpleDateFormat 语法与其他定义进行比较的工作吗?

最佳答案

java.text.*,在 JDK 1.1 中引入,基于 ICU :

ICU was originally developed by the Unicode group at the IBM Globalization Center of Competency in Cupertino, and ICU was contributed to Sun for inclusion into the JDK 1.1. ICU4J includes enhanced versions of some of these contributed classes plus additional classes that complement the classes in the JDK.

ICU 拥有 SimpleDateFormat声明其符号基于“UTS#35 Unicode 区域设置数据标记语言 (LDML) 定义的算法和模式字母”,可在 here 中找到.

有趣的是,在 Revision 3 中的 Unicode 技术报告 #35 中引入了日期模式章节。从 2004-10-27。也许当时 ICU 就是原作者?

关于java - SimpleDateFormat 的格式化语法是 Java 发明的吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32376634/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com