android-money
Simple money and currency library for android (written in kotlin).
Create Money
Creating money is as easy as:
I saved 1.358,03 €
Convert Money
Also converting between currencies is straight forward:
I could invest my 1.358,03 € and get 0,28020846 XBT instead
Money Calculations
Simple Arithmetics
If using kotlin just use the default operators (+,-,*, /) or in java (.plus()
, .minus()
, ...):
So in total I've now 1.358,03 €
Summing up / Average
For summing up the MoneyList
can be used:
In total I got: $134.65
Add Library
Step 1. Add the JitPack repository to your build file
Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Step 2. Add the dependency
dependencies {
implementation 'com.github.tobiasschuerg:android-money:v0.3'
}