自动化立体仓库 - WCS系统
luxiaotao1123
2020-09-08 28a7821e43bd5763739fe67384cfea6693b3500b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package com.zy.asrs.utils;
 
import com.core.common.Arith;
 
import java.math.BigDecimal;
import java.text.DecimalFormat;
 
/**
 * Created by vincent on 2020/8/27
 */
public class Utils {
 
    private static final DecimalFormat fmt = new DecimalFormat("##0.00");
 
    public static float scale(Float f){
        if (f == null || f == 0f || Float.isNaN(f)) {
            return 0f;
        }
        return (float) Arith.multiplys(2, f, 1);
    }
 
}