Code example for NumberFormat

Methods: setMaximumFractionDigits

0
    protected CylinderRegion region;
    protected static final NumberFormat format;
 
    static { 
        format = (NumberFormat) NumberFormat.getInstance().clone();
        format.setMaximumFractionDigits(3);
    } 
 
    public CylinderRegionSelector(LocalWorld world) {
        region = new CylinderRegion(world);
    } 
 
    public CylinderRegionSelector(RegionSelector oldSelector) {
        this(oldSelector.getIncompleteRegion().getWorld());
        if (oldSelector instanceof CylinderRegionSelector) {
            final CylinderRegionSelector cylSelector = (CylinderRegionSelector) oldSelector;
 
            region = new CylinderRegion(cylSelector.region);
        } else { 
            final Region oldRegion;
            try {