Here you can find the source of arrayToString(Object[] array, String split)
public static String arrayToString(Object[] array, String split)
//package com.java2s; //License from project: Apache License public class Main { public static String arrayToString(Object[] array, String split) { if (array == null) { return ""; } else {// ww w . j a va 2 s . c o m StringBuffer str = new StringBuffer(""); for (int i = 0; i < array.length; ++i) { if (i != array.length - 1) { str.append(array[i].toString()).append(split); } else { str.append(array[i].toString()); } } return str.toString(); } } }