ICU 对于“独立”值有不同的格式符号。例如:
q Stand Alone quarter
L Stand Alone month in year
c Stand Alone local day of week
"Stand Alone" values refer to those designed to stand on their own, as opposed to being with other formatted values. "2nd quarter" would use the stand alone format (QQQQ), whereas "2nd quarter 2007" would use the regular format (qqqq yyyy).
但是,这并不能解释为什么存在区别。我认为这对于某些语言很重要,但是有哪些例子?
(更令人困惑的是,该文档自相矛盾,因为它同时使用 q
和 Q
作为独立版本。)
我还认为其他字段(例如年、小时、分钟、秒)不需要独立版本,因为这些字段是数字。但是,如果是这种情况,为什么工作日、月份和季度的独立值支持数字形式?
最佳答案
区别与 ie 波兰语相关,其中表达日期 dd MMMM yyyy
: "22 września 2022" 与日历中仅表达 ie 的月份不同 LLLL yyyy
:“wrzesień 2022”。
关于icu - 为什么 ICU 对日期的 "stand alone"值进行区分?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/63406432/