Arraylist转换成字符串数组

public static String[] convertToStringArray(ArrayList<String> list) {
    String[] covertedArray = new String[list.size()];
    covertedArray = (String[]) list.toArray(covertedArray);
    return covertedArray;
}

你可能感兴趣的:(Arraylist转换成字符串数组)