4
我試圖進行貨幣轉換與莫尼塔的API,所以我稱之爲:JSR-354的Java錢莫尼塔指定代理
MonetaryConversions.getExchangeRateProvider("IDENT", "ECB", "IMF", "ECB-HIST", "ECB-HIST90").getExchangeRate(sourceCurrency, targetCurrency);
不幸的是我得到這個異常:
2016-06-15 17:14:12,659 [main] ERROR: Failed to load resource: IMFHistoricRateProvider
java.lang.IllegalStateException: Failed to load remote as well as fallback resources for LoadableResource [resourceId=IMFHistoricRateProvider, fallbackLocation=jar:file:/C:/Users/e-tahchpet/.m2/repository/org/javamoney/moneta/1.1/moneta-1.1.jar!/java-money/defaults/IMF/rms_five.xls, remoteResources=[http://www.imf.org/external/np/fin/data/rms_five.aspx?tsvflag=Y], loadCount=0, accessCount=1, lastLoaded=0]
at org.javamoney.moneta.internal.loader.LoadableResource.getData(LoadableResource.java:378)
我很確定這是因爲我在企業防火牆後面。有沒有辦法指定代理?一些屬性文件中的My??