top.hendrixshen.magiclib.util.minecraft.StringUtil Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of magiclib-minecraft-api-1.19.3-fabric Show documentation
Show all versions of magiclib-minecraft-api-1.19.3-fabric Show documentation
Unleash magic into Minecraft, infuse souls, ascend to heaven!
package top.hendrixshen.magiclib.util.minecraft;
import java.text.NumberFormat;
public class StringUtil {
public static String fractionDigit(double value, int digit) {
NumberFormat nf = NumberFormat.getNumberInstance();
nf.setMinimumFractionDigits(digit);
nf.setMaximumFractionDigits(digit);
return nf.format(value);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy