There are basic types and reference types in java. In the basic type, values such as numerical values and characters are stored, and arithmetic processing using the stored values is performed.
However, there is no means for manipulating values. Also, if you try to use a collection or generic that is easily performed by complicated processing, the basic type cannot be used because it is not the target of the argument.
Therefore, a class is prepared that wraps the value of the basic data type and makes it available as an object.
Call them wrapper classes.
Recommended Posts