package com.vaadin.tests.converter; import java.text.NumberFormat; import java.util.Locale; import com.vaadin.v7.data.util.converter.StringToDoubleConverter; public class StringToDoubleConverterWithThreeFractionDigits extends StringToDoubleConverter { @Override protected NumberFormat getFormat(Locale locale) { NumberFormat format = super.getFormat(locale); format.setGroupingUsed(false); format.setMaximumFractionDigits(3); format.setMinimumFractionDigits(3); return format; } }