Class: Portage::Ucp::Money
- Inherits:
-
Data
- Object
- Data
- Portage::Ucp::Money
- Defined in:
- lib/portage/ucp/value_objects.rb
Overview
Internal arithmetic helper only — never appears in a wire shape directly. Cart/Checkout/Order totals are bare minor-unit integers (Total#amount) once they reach a value object; Money exists so Support::Amounts has somewhere to hand back both the minor-unit amount and its currency together mid-conversion. Product/Variant carry currency-bearing wire fields directly (Price, below) rather than through Money.
Instance Attribute Summary collapse
-
#amount_minor ⇒ Object
readonly
Returns the value of attribute amount_minor.
-
#currency ⇒ Object
readonly
Returns the value of attribute currency.
Instance Attribute Details
#amount_minor ⇒ Object (readonly)
Returns the value of attribute amount_minor
9 10 11 |
# File 'lib/portage/ucp/value_objects.rb', line 9 def amount_minor @amount_minor end |
#currency ⇒ Object (readonly)
Returns the value of attribute currency
9 10 11 |
# File 'lib/portage/ucp/value_objects.rb', line 9 def currency @currency end |