RWMoney<T> objects in Money.h++ can be types double, and RWDecimal<RWMPXInt> where X is 1, 2, or 3.
When you create a money object in Java, the value's type can be either BigDecimal or double. These types can be mixed in arithmetic operations, but, in such cases, Java will automatically convert any floating point value to a decimal value. For example:
//decimal Money m1 = new Money("4.79","USD"); //floating point Money m2 = new Money(3.38d, "USD"); //Result of a calculation is decimal Money m3 = m1.plus(m2);
©Copyright 1999, Rogue Wave Software, Inc.
Contact Rogue Wave about documentation or support issues.