Here you can find the source of splitArray(String[] srcArr, int start, int end)
public static String[] splitArray(String[] srcArr, int start, int end)
//package com.java2s; //License from project: Open Source License import java.util.ArrayList; import java.util.List; public class Main { public static String[] splitArray(String[] srcArr, int start, int end) { List<Object> result = new ArrayList<Object>(); if (start < 0) { throw new ArrayIndexOutOfBoundsException(); }/*from w w w . j ava2 s . c o m*/ end = end > srcArr.length ? srcArr.length : end; for (int i = start; i < end; i++) { result.add(srcArr[i]); } return result.toArray(new String[0]); } }