Basic types of packaging
byte | Byte |
short | Short |
int | Integer |
long | Long |
float | Float |
double | Double |
char | Character |
boolean | Boolean |
Number of digital type packaging abstract parent class
She subclasses:
Byte,Short,Integer ,Long,Float,Double
BigDecimal,BigInteger
Remove the encapsulated primitive values
byte value ();
shortValue();
intValue();
long value ();
floatValue ();
doubleValue();
Integer
Create objects;
new Integer(5);
Integer.value(5);
Examples of internal Integer, Integer has a buffer array example,
Integer object cache with 256,
Numerical ranges package -128-127
valueOf () method, the specified range of values,
Access cached objects exist, value outside the specified range,
Direct New Object