Update date_time.json

corrected: all test passed
the  year's RE section can be improved
pull/1912/head
Ale 2018-12-23 11:11:42 +01:00 committed by GitHub
parent 404316fa70
commit 62afba6011
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 31 additions and 8 deletions

View File

@ -3,27 +3,34 @@
"1": {"match": "^\\d$", "format": "{x}"}, "1": {"match": "^\\d$", "format": "{x}"},
"2": {"match": "^1\\d$", "format": "{xx}"}, "2": {"match": "^1\\d$", "format": "{xx}"},
"3": {"match": "^\\d0$", "format": "{x0}"}, "3": {"match": "^\\d0$", "format": "{x0}"},
"4": {"match": "^[2-9]\\d$", "format": "{x0}{x}"}, "4": {"match": "^[2-9][1|8]", "format": "{xx}"},
"5": {"match": "^[2-9]\\d$", "format": "{x0}{x}"},
"default": "{number}" "default": "{number}"
}, },
"hundreds_format": { "hundreds_format": {
"1": {"match": "^1\\d{2}$", "format": "cento"}, "1": {"match": "^1\\d{2}$", "format": "cento"},
"2": {"match": "^\\d{3}$", "format": "{x_in_x00}cento"}, "2": {"match": "^\\d{3}$", "format": "{x_in_x00}cento"},
"default": "{number}" "default": "{number}"
}, },
"thousand_format": { "thousand_format": {
"1": {"match": "^1\\d{3}$", "format": "mille"}, "1": {"match": "^1\\d{3}$", "format": "mille"},
"2": {"match": "^2\\d{3}$", "format": "duemila"}, "2": {"match": "^\\d{4}$", "format": "{x_in_x000}mila"},
"3": {"match": "^\\d{4}$", "format": "{x0_in_x000}mila"},
"default": "{number}" "default": "{number}"
}, },
"year_format": { "year_format": {
"1": {"match": "^\\d\\d?$", "format": "{formatted_decade} {bc}"}, "1": {"match": "^\\d\\d?$", "format": "{formatted_decade} {bc}"},
"2": {"match": "^\\d00$", "format": "{formatted_hundreds} {bc}"}, "2": {"match": "^\\d00$", "format": "{formatted_hundreds} {bc}"},
"3": {"match": "^\\d{3}$", "format": "{formatted_hundreds} {formatted_decade} {bc}"}, "3": {"match": "^\\d000$", "format": "{formatted_thousand} {bc}"},
"4": {"match": "^(1\\d00)|([2-9]000)$", "format": "{formatted_thousand} {bc}"}, "4": {"match": "^\\d{3}$", "format": "{formatted_hundreds} {formatted_decade} {bc}"},
"5": {"match": "^(1\\d{3})|(\\d0\\d{2})$", "format": "{formatted_thousand} e {formatted_decade} {bc}"}, "5": {"match": "^1[0-9]00$", "format": "{formatted_thousand} {formatted_hundreds} {bc}"},
"6": {"match": "^\\d{4}$", "format": "{formatted_thousand} {formatted_hundreds} {formatted_decade} {bc}"}, "6": {"match": "^10\\d{2}$", "format": "{formatted_thousand} e {formatted_decade} {bc}"},
"7": {"match": "^[2-9][0-9]00$", "format": "{formatted_thousand} {formatted_hundreds} {bc}"},
"8": {"match": "^20\\d{2}$", "format": "{formatted_thousand} {formatted_decade} {bc}"},
"9": {"match": "^(1\\d{3})|(\\d0\\d{2})$", "format": "{formatted_thousand} {formatted_hundreds} {formatted_decade} {bc}"},
"10": {"match": "^[2-9]000$", "format": "{formatted_thousand} {bc}"},
"11": {"match": "^20\\d{2}$", "format": "{formatted_thousand} {formatted_decade} {bc}"},
"12": {"match": "^([2-9]\\d{3})|(\\d0\\d{2})$", "format": "{formatted_thousand} {formatted_hundreds} {formatted_decade} {bc}"},
"13": {"match": "^\\d{4}$", "format": "{formatted_thousand} {formatted_hundreds} {formatted_decade} {bc}"},
"default": "{year} {bc}", "default": "{year} {bc}",
"bc": "d.c." "bc": "d.c."
}, },
@ -116,13 +123,29 @@
"18": "diciotto", "18": "diciotto",
"19": "diciannove", "19": "diciannove",
"20": "venti", "20": "venti",
"21": "ventuno",
"28": "ventotto",
"30": "trenta", "30": "trenta",
"31": "trentuno",
"38": "trentotto",
"40": "quaranta", "40": "quaranta",
"41": "quarantuno",
"48": "quarantotto",
"50": "cinquanta", "50": "cinquanta",
"51": "cinquantuno",
"58": "cinquantotto",
"60": "sessanta", "60": "sessanta",
"61": "sessantuno",
"68": "sessantotto",
"70": "settanta", "70": "settanta",
"71": "settantuno",
"78": "settantotto",
"80": "ottanta", "80": "ottanta",
"81": "ottantuno",
"88": "ottantotto",
"90": "novanta", "90": "novanta",
"91": "novantuno",
"98": "novantotto",
"100": "cento", "100": "cento",
"1000": "mille", "1000": "mille",
"2000": "duemila" "2000": "duemila"