Class: Moolah::Rounder
- Inherits:
-
Object
- Object
- Moolah::Rounder
- Defined in:
- lib/moolah/rounder.rb
Instance Method Summary collapse
- #bankers_rounded ⇒ Object
-
#initialize(money) ⇒ Rounder
constructor
A new instance of Rounder.
Constructor Details
#initialize(money) ⇒ Rounder
Returns a new instance of Rounder.
3 4 5 |
# File 'lib/moolah/rounder.rb', line 3 def initialize(money) @money = money end |
Instance Method Details
#bankers_rounded ⇒ Object
7 8 9 |
# File 'lib/moolah/rounder.rb', line 7 def bankers_rounded Money.new(amount: bankers_rounded_amount, currency: money.currency, fx_rate: money.fx_rate) end |