Transfer from http://blog.csdn.net/zhang103886108/article/details/42917693
1. How can I convert string strings to integer int?
int i = integer.valueof (my_str). Intvalue ();
int I=integer.parseint (str);
2. How can I convert string strings to integers?
Integer integer=integer.valueof (str);
3. How to convert integer int into string string?
1.) String s = string.valueof (i);
2.) String s = integer.tostring (i);
3.) String s = "" + I;
4. How do I convert an integer int to an integer?
Integer integer=new integer (i);
6. How do I convert an integer to int?
int Num=integer.intvalue ();
12, string to double
String s;
Double ss=double.parsedouble (s);
Note: parsedouble parseint returns a double.
Double and Integer are encapsulated classes of double and int that need to be converted to a string type.
String,int,integer,char, double type conversions in Java