#java #javatutorial #javacourse
00:00:00 introduction
00:02:34 autoboxing
00:03:30 unboxing
00:04:41 toString
00:06:30 parsing
00:08:38 misc methods
00:10:06 conclusion
public class Main {
public static void main(String[] args) {
// Wrapper classes = Allow primitive values (int, char, double, boolean)
// to be used as objects. "Wrap them in an object"
// Generally, don't wrap primitives unless you need an object.
// Allows use of Collections Framework and static utility methods.
// Autoboxing
Integer a = 123;
Double b = 3.14;
Character c = '$';
Boolean d = true;
// Unboxing
int x = a;
}
}
コメント