char数组转list

方法1

1
myString.chars().mapToObj(c -> (char) c).collect(Collectors.toList());

方法2

1
2
3
4
5
6
7
8
String s = "asdasdasda";
char[] chars = s.toCharArray();
List<char[]> asList = Arrays.asList(chars);

List<Character> listC = new ArrayList<Character>();
for (char c : chars) {
listC.add(c);
}