Here you can find the source of convertArray(String[] str)
public static int[] convertArray(String[] str)
//package com.java2s; //License from project: LGPL public class Main { public static int[] convertArray(String[] str) { try {//w w w .j av a 2 s . c o m int[] strs = new int[str.length]; for (int i = 0; i < str.length; i++) { strs[i] = Integer.parseInt(str[i]); } return strs; } catch (Exception e) { return null; } } }