What is the number wrapper class and its methods in Java?

vanithasree
Updated on 30-Jul-2019 22:30:20

284 Views

The Number class (abstract) of the java.lang package represents the numeric values that are convertible to primitive types byte, double, float, int, long, and short. Following are the method provided by the Number class of the java.lang package. Sr.No Method & Description 1 byte byteValue() This method returns the value of the specified number as a byte. 2 abstract double doubleValue() This method returns the value of the specified number as a double. 3 abstract float floatValue() This method returns the value of the specified number as a float. ... Read More

Advertisements