提交 06547293 编写于 作者: Y yhuang

7077119: remove past transition dates from CurrencyData.properties file

Reviewed-by: naoto
上级 e87e49c7
......@@ -71,7 +71,7 @@ all=ADP020-AED784-AFA004-AFN971-ALL008-AMD051-ANG532-AOA973-ARS032-ATS040-AUD036
#
# The table is based on the following web sites:
# http://www.din.de/gremien/nas/nabd/iso3166ma/codlstp1/db_en.html
# http://www.bsi-global.com/iso4217currency
# http://www.currency-iso.org/iso_index/iso_tables.htm
# http://www.cia.gov/cia/publications/factbook/indexgeo.html
# AFGHANISTAN
......@@ -105,7 +105,7 @@ AU=AUD
# AUSTRIA
AT=EUR
# AZERBAIJAN
AZ=AZM;2005-12-31-20-00-00;AZN
AZ=AZN
# BAHAMAS
BS=BSD
# BAHRAIN
......@@ -378,7 +378,7 @@ MS=XCD
# MOROCCO
MA=MAD
# MOZAMBIQUE
MZ=MZM;2006-06-30-22-00-00;MZN
MZ=MZN
# MYANMAR
MM=MMK
# NAMIBIA
......@@ -440,7 +440,7 @@ QA=QAR
# REUNION
RE=EUR
# ROMANIA
RO=ROL;2005-06-30-21-00-00;RON
RO=RON
# RUSSIAN FEDERATION
RU=RUB
# RWANDA
......@@ -532,7 +532,7 @@ TT=TTD
# TUNISIA
TN=TND
# TURKEY
TR=TRL;2004-12-31-22-00-00;TRY
TR=TRY
# TURKMENISTAN
TM=TMT
# TURKS AND CAICOS ISLANDS
......@@ -558,7 +558,7 @@ UZ=UZS
# VANUATU
VU=VUV
# VENEZUELA
VE=VEB;2008-01-01-04-00-00;VEF
VE=VEF
# VIET NAM
VN=VND
# VIRGIN ISLANDS, BRITISH
......
......@@ -128,18 +128,20 @@ public class CurrencyTest {
checkCountryCurrency(country1[i], currency1[i]);
}
// check currency changes
String[] switchOverCtry = {"DE", "FR", "ES", "IT", "NL", "BE", "TR", "RO", "AZ", "MZ", "GH", "VE"};
String[] switchOverOld = {"DEM", "FRF", "ESP", "ITL", "NLG", "BEF", "TRL", "ROL", "AZM", "MZM", "GHC", "VEB"};
String[] switchOverNew = {"EUR", "EUR", "EUR", "EUR", "EUR", "EUR", "TRY", "RON", "AZN", "MZN", "GHS", "VEF"};
String[] switchOverTZ = {"Europe/Paris", "Europe/Paris", "Europe/Paris", "Europe/Paris",
"Europe/Paris", "Europe/Paris", "Asia/Istanbul", "Europe/Bucharest",
"Asia/Baku", "Africa/Maputo", "Africa/Accra", "America/Caracas"};
int[] switchOverYear = {2002, 2002, 2002, 2002, 2002, 2002, 2005, 2005, 2006, 2006, 2007, 2008};
int[] switchOverMonth = {Calendar.JANUARY, Calendar.JANUARY, Calendar.JANUARY, Calendar.JANUARY,
Calendar.JANUARY, Calendar.JANUARY, Calendar.JANUARY, Calendar.JULY,
Calendar.JANUARY, Calendar.JULY, Calendar.JULY, Calendar.JANUARY};
int[] switchOverDay = {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1};
/*
* check currency changes
* In current implementation, there is no data of old currency and transition date at jdk/src/share/classes/java/util/CurrencyData.properties.
* So, all the switch data arrays are empty. In the future, if data of old currency and transition date are necessary for any country, the
* arrays here can be updated so that the program can check the currency switch.
*/
String[] switchOverCtry = {};
String[] switchOverOld = {};
String[] switchOverNew = {};
String[] switchOverTZ = {};
int[] switchOverYear = {};
int[] switchOverMonth = {};
int[] switchOverDay = {};
for (int i = 0; i < switchOverCtry.length; i++) {
TimeZone.setDefault(TimeZone.getTimeZone(switchOverTZ[i]));
Calendar date = new GregorianCalendar(switchOverYear[i], switchOverMonth[i], switchOverDay[i]);
......
......@@ -92,7 +92,7 @@ public class ValidateISO4217 {
/* Codes that are obsolete, do not have related country */
static final String otherCodes =
"ADP-AFA-ATS-AYM-BEF-BGL-BOV-BYB-CLF-CUC-CYP-DEM-EEK-ESP-FIM-FRF-GRD-GWP-IEP-ITL-LUF-MGF-MTL-MXV-NLG-PTE-RUR-SDD-SIT-SKK-SRG-TMM-TPE-TRL-VEF-USN-USS-XAG-XAU-XBA-XBB-XBC-XBD-XDR-XFO-XFU-XPD-XPT-XSU-XTS-XUA-XXX-YUM-ZWD-ZWN-ZWR";
"ADP-AFA-ATS-AYM-AZM-BEF-BGL-BOV-BYB-CLF-CUC-CYP-DEM-EEK-ESP-FIM-FRF-GHC-GRD-GWP-IEP-ITL-LUF-MGF-MTL-MXV-MZM-NLG-PTE-ROL-RUR-SDD-SIT-SKK-SRG-TMM-TPE-TRL-VEF-USN-USS-VEB-XAG-XAU-XBA-XBB-XBC-XBD-XDR-XFO-XFU-XPD-XPT-XSU-XTS-XUA-XXX-YUM-ZWD-ZWN-ZWR";
static boolean err = false;
......
......@@ -23,7 +23,7 @@ AW AWG 533 2
AU AUD 36 2
AT EUR 978 2
# MA 129
AZ AZM 31 2 2005-12-31-20-00-00 AZN 944 2
AZ AZN 944 2
BS BSD 44 2
BH BHD 48 3
BD BDT 50 2
......@@ -96,7 +96,7 @@ GA XAF 950 0
GM GMD 270 2
GE GEL 981 2
DE EUR 978 2
GH GHC 288 2 2007-07-01-00-00-00 GHS 936 2
GH GHS 936 2
GI GIP 292 2
GR EUR 978 2
GL DKK 208 2
......@@ -166,7 +166,7 @@ MN MNT 496 2
MS XCD 951 2
MA MAD 504 2
# MA 130
MZ MZM 508 2 2006-06-30-22-00-00 MZN 943 2
MZ MZN 943 2
MM MMK 104 2
# MA 134
ME EUR 978 2
......@@ -200,7 +200,7 @@ PT EUR 978 2
PR USD 840 2
QA QAR 634 2
RE EUR 978 2
RO ROL 946 2 2005-06-30-21-00-00 RON 946 2
RO RON 946 2
RU RUB 643 2
RW RWF 646 0
SH SHP 654 2
......@@ -266,7 +266,7 @@ UM USD 840 2
UY UYU 858 2
UZ UZS 860 2
VU VUV 548 0
VE VEB 862 2 2008-01-01-04-00-00 VEF 937 2
VE VEF 937 2
VN VND 704 2
VG USD 840 2
VI USD 840 2
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册