List<String>转String
String Message="";
for (String msg : message) {
Message = Message.concat(msg);
}
String转List<String>
import java.util.ArrayList;
import java.util.List;
public class Str {
public static void main(String[] args) {
String s = "64,127,248,569";
String d[] = s.split(",");
List<String> list = new ArrayList<String>();
for (int i = 0; i < d.length; i++) {
list.add(d[i]);
}
System.out.println(list);
}
}