Class: Moolah::Rounder

Inherits:
Object
  • Object
show all
Defined in:
lib/moolah/rounder.rb

Instance Method Summary collapse

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_roundedObject



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