@Override public String getInternationalCurrencySymbol() { return fIcuDecfs.getInternationalCurrencySymbol(); }
/** * Returns the currency in effect for this formatter. Subclasses should override this * method as needed. Unlike getCurrency(), this method should never return null. * * @internal * @deprecated This API is ICU internal only. */ @Deprecated @Override protected Currency getEffectiveCurrency() { Currency c = getCurrency(); if (c == null) { c = Currency.getInstance(symbols.getInternationalCurrencySymbol()); } return c; }
/** * Update the currency object to match the symbols. This method is used only when the * caller has passed in a symbols object that may not be the default object for its * locale. */ private void setCurrencyForSymbols() { // Bug 4212072 Update the affix strings according to symbols in order to keep the // affix strings up to date. [Richard/GCL] // With the introduction of the Currency object, the currency symbols in the DFS // object are ignored. For backward compatibility, we check any explicitly set DFS // object. If it is a default symbols object for its locale, we change the // currency object to one for that locale. If it is custom, we set the currency to // null. DecimalFormatSymbols def = new DecimalFormatSymbols(symbols.getULocale()); if (symbols.getCurrencySymbol().equals(def.getCurrencySymbol()) && symbols.getInternationalCurrencySymbol() .equals(def.getInternationalCurrencySymbol())) { setCurrency(Currency.getInstance(symbols.getULocale())); } else { setCurrency(null); } }
s = intl ? symbols.getInternationalCurrencySymbol() : symbols.getCurrencySymbol();
fieldPosition.setBeginIndex(start); fieldPosition.setEndIndex(end); } else if (affix.indexOf(symbols.getInternationalCurrencySymbol()) > -1) { String aff = symbols.getInternationalCurrencySymbol(); int firstPos = affix.indexOf(aff); int start = buf.length() + firstPos;