Here you can find the source of parseBigDecimal(Object o, BigDecimal defaulti)
public static BigDecimal parseBigDecimal(Object o, BigDecimal defaulti)
//package com.java2s; import java.math.BigDecimal; public class Main { public static BigDecimal parseBigDecimal(Object o, BigDecimal defaulti) { try {// w ww . ja v a 2 s . c o m return new BigDecimal(o.toString()); } catch (Exception e) { return defaulti; } } }