I.intvalue () to extract the value of I
Use occasions, such as saying
To ArrayList inside add, must add is an object
and int is not an object, it can only be added to the integer.
Almost everything you want to work with in Java is an object, and basic data types, such as defined variables such as int,double and the letter constants in your program, are not objects. An integer is wrapping an int base data type as an object, which is called boxing (autoboxing) in Java, for example:
Integer i = new Integer (10);
is to instantiate I as an object. The auto-boxing function is provided after Java5.0, as with the example above:
Integer i = 10;
Specific things still suggest you find detailed information to learn.
int i = 0;
Integer j = new Integer (0);
i = = J.intvalue () true;
In java1.4 and the previous version of the basic type int double is not directly placed in the list, map, etc., must be converted to an integer or double type to be
What's the difference between int and integer in Java?