floatValue
public float floatValue()
Converts this BigDecimal to a float. Similar to the double-to-float narrowing primitive conversion defined in The Java Language Specification: if this BigDecimal has too great a magnitude to represent as a float, it will be converted to Float.NEGATIVE_INFINITY or Float.POSITIVE_INFINITY as appropriate. Specified by:
floatValue in class Number
Returns:
this BigDecimal converted to a float.
public float floatValue()
Converts this BigDecimal to a float. Similar to the double-to-float narrowing primitive conversion defined in The Java Language Specification: if this BigDecimal has too great a magnitude to represent as a float, it will be converted to Float.NEGATIVE_INFINITY or Float.POSITIVE_INFINITY as appropriate. Specified by:
floatValue in class Number
Returns:
this BigDecimal converted to a float.
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货