Currency SFO
info
The Currency object differs from the CartCurrency object. The cart currency is a simple object that is mainly supplied as a list of possible currencies so a select box can be created which allows the customer to change the currency. The Currency object has additional methods that help with conversion rates, etc. The Currency object is used on Catalog pages, and the CartCurrency object is found within Checkout pages.
Properties
| Field | Type | Comment/Sample |
|---|
Methods
| Method | Signature | Comments/Sample |
|---|---|---|
add | Currency add(Currency val) | |
compareTo | integer compareTo(Currency val) | |
getConversionRate | [BigDecimal](./bigdecimal-sfo.md) getConversionRate(string fromCurrency, string toCurrency) | |
getInUOM | Currency getInUOM(string uom) | |
getUom | string getUom() | |
getValue | [BigDecimal](./bigdecimal-sfo.md) getValue() | |
getValueInUOM | [BigDecimal](./bigdecimal-sfo.md) getValueInUOM(string uom) | |
isNonZero | boolean isNonZero() | |
isZero | boolean isZero() | |
multiply | Currency multiply(integer val) | |
multiply | Currency multiply([BigDecimal](./bigdecimal-sfo.md) val) | |
subtract | Currency subtract(Currency val) |
See Also
Was this page helpful?