One overarching change is that CLDC does not support floating-point types at all. That means there are no float or double primitive types. The corresponding wrapper types, java.lang.Float and java.lang.Double, have also been eliminated.
Floating point support is absent in CLDC because most small devices don't have hardware support for floating-point operations. If calculations involving fractional numbers are important to your application, you can perform them in software. One implementation (using fixed-point integers) can be found at http://home.rochester.rr.com/ohommes/MathFP/.
Team-Fly |