Package Framework

Examples of Framework.DecimalFormatter


    public static DataField newAmountField(String name, int columns, Class<?> mappedType) {
        return newAmountField(name, columns, "'$'#,##0.00", 2, mappedType);
    }

    public static DataField newDecimalField(String name, int columns, String pattern, int decimalPlaces, Class<?> mappedType) {
        DecimalFormatter editFormatter = new DecimalFormatter(pattern, decimalPlaces, mappedType);
        DecimalFormatter displayFormatter = new DecimalFormatter(pattern, decimalPlaces, mappedType);
        DataField df = newDataField(name, columns, new DefaultFormatterFactory(displayFormatter, displayFormatter, editFormatter, null));
        return df;     
    }
View Full Code Here


    public static DataField newAmountField(String name, int columns, Class<?> mappedType) {
        return newAmountField(name, columns, "'$'#,##0.00", 2, mappedType);
    }

    public static DataField newDecimalField(String name, int columns, String pattern, int decimalPlaces, Class<?> mappedType) {
        DecimalFormatter editFormatter = new DecimalFormatter(pattern, decimalPlaces, mappedType);
        DecimalFormatter displayFormatter = new DecimalFormatter(pattern, decimalPlaces, mappedType);
        DataField df = newDataField(name, columns, new DefaultFormatterFactory(displayFormatter, displayFormatter, editFormatter, null));
        return df;     
    }
View Full Code Here

TOP

Related Classes of Framework.DecimalFormatter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.