rapper class is provides wrapper around a primitive data type so that we can use it as abjects. An instance of a wrapper class contains, or wraps, a primitive value of the corresponding type.
Following table lists the primitive types and the corresponding wrapper classes:
Primitive |
Wrapper |
boolean |
java.lang.Boolean |
byte |
java.lang.Byte |
char |
java.lang.Character |
double |
java.lang.Double |
float |
java.lang.Float |
int |
java.lang.Integer |
long |
java.lang.Long |
short |
java.lang.Short |
void |
java.lang.Void |