Here you can find the source of toDouble(String value)
public static Double toDouble(String value)
//package com.java2s; //License from project: Open Source License public class Main { public static Double toDouble(String value) { if (null == value) { return null; }/*from w w w. j a v a 2 s . c om*/ value = value.trim(); if ("null".equals(value)) { return null; } return Double.parseDouble(value); } public static Double toDouble(Object value) { return toDouble(String.valueOf(value)); } }