数组:
public static void main(String[] args) {
List<String> list = new ArrayList<String>();
list.add("1");
list.add("2");
list.add("3"); System.out.println(list.toString());
System.out.println(StringUtils.strip(list.toString(),"[]"));
}
结果:[1, 2, 3] 1, 2, 3
字符串:
String str=list.get(0).get("phoneList");
String phoneIdList =StringUtils.strip(str,"[]");