





Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
The concept of wrapper classes in Java, which allow primitive data types to be treated as objects. Wrapper classes, such as Double, Integer, and Boolean, provide methods for converting between strings and primitive types, and enable primitive data to be included in Object arrays. The document also covers the UML class diagram for wrapper classes, constructing wrapped numbers, and automatic conversion between primitive and wrapper types.
Typology: Study notes
1 / 9
This page cannot be seen from the preview
Don't miss anything!






NOTE: all wrapper classes capitalize the name of the associated primitive type, except for Integer and Character. UML Class Diagram for Wrapper Classes
Converting Between Strings and Primitive Numeric Types Converting to String
Converting from String
Example: A Polymorphic (“Generic”) Sorting Method
(implementation of Selection Sort: iteratively finds largest element, places it at the end of the array)