Java Double Number Create toDouble(Object prmIntObject)

Here you can find the source of toDouble(Object prmIntObject)

Description

to Double

License

Apache License

Declaration

public static double toDouble(Object prmIntObject) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static double toDouble(Object prmIntObject) {
        double rtnDouble = 0;
        if (prmIntObject != null) {
            if (prmIntObject.toString() != "") {
                rtnDouble = Double.parseDouble(prmIntObject.toString());
            }//  w  ww  . j  av a  2s  . c  o  m
        }
        return rtnDouble;
    }

    public static String toString(Object stringObject) {
        return toString(stringObject, "");
    }

    public static String toString(Object stringObject, String value2) {
        if (stringObject != null) {
            return stringObject.toString();
        } else {
            return value2;
        }
    }
}

Related

  1. toDouble(Object obj)
  2. toDouble(Object object)
  3. toDouble(Object object, double defaultValue)
  4. toDouble(Object object, Double defaultValue)
  5. toDouble(Object objValue)
  6. toDouble(Object val)
  7. toDouble(Object val)
  8. toDouble(Object val)
  9. toDouble(Object value)