Here you can find the source of getIntNum(Double value)
public static int getIntNum(Double value)
//package com.java2s; //License from project: Open Source License import java.text.DecimalFormat; public class Main { public static int getIntNum(Double value) { DecimalFormat df = new DecimalFormat("#"); String str = df.format(value).replaceAll("-", ""); return str.length(); }//from www. ja v a2 s . c o m }