Here you can find the source of toDouble(Number value)
Parameter | Description |
---|---|
value | number object |
public static double toDouble(Number value)
//package com.java2s; //License from project: LGPL public class Main { /**//www . java 2 s . c o m * Turns a Number object into a double primitive. * If the supplied value is null, Double.NaN is returned. * * @param value number object * @return primitive value */ public static double toDouble(Number value) { return value == null ? Double.NaN : value.doubleValue(); } }