0% found this document useful (0 votes)
31 views

Methods of Java Wrapper Class

The document discusses some methods defined by the Character, Integer, Float and Double wrapper classes in Java. It lists the name, syntax, return type and argument type of methods like isLetter(), parseInt(), toString() and parseDouble().

Uploaded by

Keerat singh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
31 views

Methods of Java Wrapper Class

The document discusses some methods defined by the Character, Integer, Float and Double wrapper classes in Java. It lists the name, syntax, return type and argument type of methods like isLetter(), parseInt(), toString() and parseDouble().

Uploaded by

Keerat singh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

ClassWithAmit Methods of Wrapper classes in Java

Some of the methods defined by Character wrapper class

Name of Syntax of method Return type Argument type


method of method of method
isLetter() boolean var=Character.isLetter(ch) boolean char
Returns true if given character is letter otherwise false.

isDigit() boolean var=Character.isDigit(ch) boolean char


Returns true if given character is digit otherwise false.

isLetterOrDigit() boolean var=Character.isLetterOrDigit(ch) boolean char


Returns true if given character is letter or digit otherwise false.

isLowerCase() boolean var=Character.isLowerCase(ch) boolean char


Returns true if given character is in lower case otherwise false.

isUpperCase() boolean var=Character.isUpperCase(ch) boolean char


Returns true if given character is in upper case otherwise false.

isWhitespace() boolean var=Character.isWhitespace(ch) boolean char


Returns true if given character is whitespace otherwise false.

toLowerCase() char var=Character.toLowerCase(ch) char char


Converts a given character into lowercase.

toUpperCase() char var=Character.toUpperCase(ch) char char


Converts a given character into uppercase.

Some of the methods defined by Integer wrapper class


parseInt() int var=Integer.parseInt(str) int String
Converts a given string into int type.

valueOf() int var=Integer.valueOf(str) int String

toBinaryString String var=Integer.toBinaryString(int) String int


Returns Binary equivalent of given int number.

toOctalString() String var=Integer.toOctalString(int) String int


Returns Octal equivalent of given int number.

toHexString() String var=Integer.toHexString(int) String int


Returns Hexa Decimal of given int number.

toString String var=Integer.toString(int) String int


Convert an int number to String type.

Some of the methods defined by Float and Double wrapper class


parseFloat() float var=Float.parseFloat(str) float String
Convert String to float data type number.

parseDouble double var=Double.parseDouble(str) double String


Convert String to double data type number.

You might also like