Here you can find the source of toFloatArray(final Object[] array)
public static float[] toFloatArray(final Object[] array)
//package com.java2s; //License from project: Open Source License public class Main { public static float[] toFloatArray(final Object[] array) { if (array == null) { return new float[0]; }/*from w ww. ja v a 2 s . c o m*/ final float[] retVal = new float[array.length]; try { for (int i = 0; i < array.length; i++) { retVal[i] = Float.parseFloat(String.valueOf(array[i])); } return retVal; } catch (Exception e) { return new float[0]; } } }