obj to double
obj to long
instance of
Bigdecimal
public static void main(String[] args) throws ParseException { Object obj1 = 1234; Object obj2 = 1234.1; BigDecimal a = new BigDecimal(obj2.toString()); System.out.println(a.longValue()); }
本文共 326 字,大约阅读时间需要 1 分钟。
obj to double
obj to long
instance of
Bigdecimal
public static void main(String[] args) throws ParseException { Object obj1 = 1234; Object obj2 = 1234.1; BigDecimal a = new BigDecimal(obj2.toString()); System.out.println(a.longValue()); }
转载于:https://www.cnblogs.com/lwmp/p/10919777.html