1. String -> Integer
int intValue = Integer.parseInt(intString);
2. String -> Double
double doubleValue = Double.parseDouble(doubleString);
3. Number -> String
String s = number + "";
或者用 String.valueOf();
例如:
String x = String.valueOf(5.44);
Introduction to Java Programming 10.th 4.4.10