Class DefaultCurrencyAmountResolutionStrategy

    • Constructor Detail

      • DefaultCurrencyAmountResolutionStrategy

        public DefaultCurrencyAmountResolutionStrategy()
    • Method Detail

      • formatCurrencyAmount

        protected java.lang.String formatCurrencyAmount​(java.util.Locale locale,
                                                        CurrencyModel currency,
                                                        java.math.BigDecimal amount)
        Format an amount in a currency for a locale.
        Parameters:
        locale - the java locale that the amount should be rendered in
        currency - the hybris currency model for the amount
        amount - the value
        Returns:
        a formatted string
      • adjustDigits

        protected java.text.DecimalFormat adjustDigits​(java.text.DecimalFormat format,
                                                       CurrencyModel currency)
        Adjusts DecimalFormat's fraction digits according to given CurrencyModel.
      • adjustSymbol

        protected static java.text.DecimalFormat adjustSymbol​(java.text.DecimalFormat format,
                                                              CurrencyModel currency)
        Adjusts DecimalFormat's symbol according to given CurrencyModel.
      • setPromotionResultUtils

        public void setPromotionResultUtils​(PromotionResultUtils promotionResultUtils)