Class CustomSymbolCurrency

  • All Implemented Interfaces:
    java.io.Serializable

    public class CustomSymbolCurrency
    extends Currency
    See Also:
    Serialized Form
    • Field Detail

      • symbol1

        private java.lang.String symbol1
      • symbol2

        private java.lang.String symbol2
    • Constructor Detail

      • CustomSymbolCurrency

        public CustomSymbolCurrency​(java.lang.String isoCode,
                                    java.lang.String currency1Sym,
                                    java.lang.String currency2Sym)
    • Method Detail

      • getName

        public java.lang.String getName​(ULocale locale,
                                        int nameStyle,
                                        boolean[] isChoiceFormat)
        Description copied from class: Currency
        Returns the display name for the given currency in the given locale. For example, the display name for the USD currency object in the en_US locale is "$".
        Overrides:
        getName in class Currency
        Parameters:
        locale - locale in which to display currency
        nameStyle - selector for which kind of name to return. The nameStyle should be SYMBOL_NAME, NARROW_SYMBOL_NAME, or LONG_NAME. Otherwise, throw IllegalArgumentException.
        isChoiceFormat - isChoiceFormat[0] is always set to false, or isChoiceFormat can be null; display names are static strings; since ICU 4.4, ChoiceFormat patterns are no longer supported
        Returns:
        display string for this currency. If the resource data contains no entry for this currency, then the ISO 4217 code is returned.

        See Also:
        Currency.getName(ULocale, int, String, boolean[])
      • getName

        public java.lang.String getName​(ULocale locale,
                                        int nameStyle,
                                        java.lang.String pluralCount,
                                        boolean[] isChoiceFormat)
        Description copied from class: Currency
        Returns the display name for the given currency in the given locale. For example, the SYMBOL_NAME for the USD currency object in the en_US locale is "$". The PLURAL_LONG_NAME for the USD currency object when the currency amount is plural is "US dollars", such as in "3.00 US dollars"; while the PLURAL_LONG_NAME for the USD currency object when the currency amount is singular is "US dollar", such as in "1.00 US dollar".
        Overrides:
        getName in class Currency
        Parameters:
        locale - locale in which to display currency
        nameStyle - selector for which kind of name to return
        pluralCount - plural count string for this locale
        isChoiceFormat - isChoiceFormat[0] is always set to false, or isChoiceFormat can be null; display names are static strings; since ICU 4.4, ChoiceFormat patterns are no longer supported
        Returns:
        display string for this currency. If the resource data contains no entry for this currency, then the ISO 4217 code is returned.
      • getCurrencyCode

        public java.lang.String getCurrencyCode()
        Description copied from class: Currency
        Returns the ISO 4217 3-letter code for this currency object.
        Overrides:
        getCurrencyCode in class Currency
      • equals

        public boolean equals​(java.lang.Object other)
        Description copied from class: MeasureUnit
        Overrides:
        equals in class MeasureUnit