Here you can find the source of toDoubleArray(final List
public static final double[] toDoubleArray(final List<Double> pItems)
//package com.java2s; import java.util.List; public class Main { public static final double[] toDoubleArray(final List<Double> pItems) { final double[] out = new double[pItems.size()]; for (int i = out.length - 1; i >= 0; i--) { out[i] = pItems.get(i);/* w ww. j a va 2s . c om*/ } return out; } }