| Modifier and Type | Field and Description |
|---|---|
private java.math.BigDecimal |
amount |
| Constructor and Description |
|---|
Money(java.math.BigDecimal amount) |
Money(double amount) |
Money(int amount) |
| Modifier and Type | Method and Description |
|---|---|
Money |
add(Money other) |
int |
compareTo(Money other) |
boolean |
equals(java.lang.Object o) |
int |
hashCode() |
static Money |
min(Money m1,
Money m2) |
Money |
subtract(Money other) |
java.lang.String |
toString() |
public Money(java.math.BigDecimal amount)
public Money(int amount)
public Money(double amount)
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic int compareTo(Money other)
compareTo in interface java.lang.Comparable<Money>