|
Copyright © 2000, 2009, Oracle and/or its affiliates. All rights reserved. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.bea.commerce.ebusiness.price.quote.AbstractMoney com.bea.commerce.ebusiness.price.quote.MutableMoney
@Deprecated public class MutableMoney
A money object that may have it's amount and currency modified.
Field Summary |
---|
Fields inherited from class com.bea.commerce.ebusiness.price.quote.AbstractMoney |
---|
NO_CURRENCY, ZERO |
Constructor Summary | |
---|---|
MutableMoney()
Deprecated Constructs a new MutableMoney object with a value of zero and a currency of "NoCurrency". |
|
MutableMoney(double value,
String currency)
Deprecated Constructs a new MutableMoney object with a value and currency as specified by the given parameters. |
Method Summary | |
---|---|
MutableMoney |
add(double value)
Deprecated Adds the specified value to this money object. |
MutableMoney |
add(Money value)
Deprecated Adds the specified Money object to this money object if the two objects have the same currency. |
static MutableMoney |
copyFromAxiomMoney(Money from,
MutableMoney to)
Deprecated Copies the values from the first parameter to the second parameter and returns the second parameter. |
static MutableMoney |
create(Money axiomMoney)
Deprecated Create a new money object from the com.beasys.commerce.axiom.units.Money object passed in. |
static MutableMoney |
create(Money money)
Deprecated Create a new immutable money object. |
static MutableMoney |
create(Money money,
double value)
Deprecated Create a new money object. |
String |
getCurrency()
Deprecated |
double |
getValue()
Deprecated |
MutableMoney |
set(double value,
String currency)
Deprecated Sets the value and currency of the object specified by the given parameters. |
MutableMoney |
set(Money money)
Deprecated Sets this object based on the values of the specified Money object. |
MutableMoney |
set(Money money,
double value)
Deprecated Sets the value and currency of the object specified by the given parameters. |
void |
setCurrency(String currency)
Deprecated Set the currency for this money object |
void |
setValue(double value)
Deprecated Set the amount for this money object |
String |
toString()
Deprecated Returns the class of the object and the value and currency of the object. |
Methods inherited from class com.bea.commerce.ebusiness.price.quote.AbstractMoney |
---|
compare, equals |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public MutableMoney()
AbstractMoney
public MutableMoney(double value, String currency)
value
- the amount of moneycurrency
- the string value of the currencyMethod Detail |
---|
public static MutableMoney create(Money axiomMoney)
axiomMoney
- a money object
Money
public static MutableMoney create(Money money, double value)
money
- a money objectvalue
- the amount of the new money object
Money
public static MutableMoney create(Money money)
money
- a money object
Money
public static MutableMoney copyFromAxiomMoney(Money from, MutableMoney to)
from
- a com.beasys.commerce.axiom.units.Money object to
copy the values fromto
- a Money object to copy the from values to
NullPointerException
Money
public MutableMoney set(double value, String currency)
value
- the amount of moneycurrency
- the string value of the currencypublic MutableMoney set(Money money, double value)
value
- the amount of moneycurrency
- the string value of the currencypublic MutableMoney set(Money money)
money
- a money object
Money
public double getValue()
getValue
in interface Money
getValue
in class AbstractMoney
public String getCurrency()
getCurrency
in interface Money
getCurrency
in class AbstractMoney
public void setValue(double value)
value
- amount of moneypublic void setCurrency(String currency)
currency
- currency to be addedpublic MutableMoney add(double value)
value
- the amount of money to add to this object
public MutableMoney add(Money value) throws CurrencyMismatchException
value
- the amount of money to add to this object
CurrencyMismatchException
public String toString()
toString
in class AbstractMoney
|
Copyright © 2000, 2009, Oracle and/or its affiliates. All rights reserved. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |