예제 #1
0
 public Ratio dividedBy(Money divisor) {
   assertHasSameCurrencyAs(divisor);
   return Ratio.of(amount, divisor.amount);
 }
예제 #2
0
 public Money plus(Money other) {
   assertHasSameCurrencyAs(other);
   return Money.valueOf(amount.add(other.amount), currency);
 }