moneyutils/src/main/kotlin/com/cubetiqs/libra/moneyutils/MoneyExtension.kt
2020-08-27 21:42:05 +07:00

7 lines
261 B
Kotlin

package com.cubetiqs.libra.moneyutils
fun StdMoney.exchangeTo(currency: String): StdMoney {
return MoneyExchangeUtils.exchange(this, currency)
}
fun StdMoney.isMatchedCurrency(currency: String) = this.getMoneyCurrency().equals(currency, ignoreCase = true)