Here you can find the source of toBigDecimal(String value)
public static BigDecimal toBigDecimal(String value)
//package com.java2s; //License from project: Open Source License import java.math.BigDecimal; public class Main { public static BigDecimal toBigDecimal(String value) { if (null == value) { return null; }/* ww w . j a va2s . co m*/ value = value.trim(); if ("null".equals(value)) { return null; } return new BigDecimal(value); } public static BigDecimal toBigDecimal(Object value) { if (null == value) { return null; } return toBigDecimal(String.valueOf(value)); } }