Android examples for java.lang:String Join
concat All string in string array
import java.util.Arrays; public class Main{ public static String[] concatAll(String[] first, String... rest) { int totalLength = first.length + rest.length; String[] result = Arrays.copyOf(first, totalLength); int offset = first.length; int x = 0; for (int i = offset; i < totalLength; i++) { result[i] = rest[x++];/* w ww. j av a 2 s. c o m*/ } return result; } public static String[] concatAll(String[] first, String[]... rest) { int totalLength = first.length; for (String[] array : rest) { totalLength += array.length; } String[] result = Arrays.copyOf(first, totalLength); int offset = first.length; for (String[] array : rest) { System.arraycopy(array, 0, result, offset, array.length); offset += array.length; } return result; } }