Interface MoneyColumn<C extends MoneyColumn<C>>

All Superinterfaces:
Column<C>, Comparable<C>, Component<C>, Copyable<C>, CustomCssComponent<C>, Serializable
All Known Implementing Classes:
DefaultMoneyColumn

public interface MoneyColumn<C extends MoneyColumn<C>> extends Column<C>
Represents the metadata for a column that displays a monetary amount. It is expected that this field targets a money object, and not a big decimal, for example:
 {
     "defaultPrice": {
         "amount": 10,
         "currency": "USD"
     }
 }
 
Author:
Nick Crum (ncrum)
  • Method Details

    • currencyCodeField

      default C currencyCodeField(String currencyCodeField)
      Sets the name of the property with the currency that should be used when formatting the amount. If no currency code field is defined, then this component will look at the `currency` on the money object.
      Parameters:
      currencyCodeField - the currency code field
      Returns:
      this
    • simpleValue

      default C simpleValue(boolean isSimpleValue)
      Parameters:
      isSimpleValue - The value to set
      Returns:
      this
      Since:
      2.x.x
    • simpleValue

      default C simpleValue()
      Sets the value of MoneyColumn.Attributes.SIMPLE_VALUE to true.
      Returns:
      this
      Since:
      2.x.x
    • complexValue

      default C complexValue()
      Sets the value of MoneyColumn.Attributes.SIMPLE_VALUE to false.
      Returns:
      this
      Since:
      2.x.x