class AbstractSliderFieldInitializer implements FieldInitializer<FIELD> {

    @Override
    public void initialize(FIELD field,
                           FieldElement fieldElement,
                           FormGenerationContext context) {
        String min = fieldElement.getParams().get("min");

        T value = getValue(min);

        if (value != null) {
            field.setMin(value);
        }

        String max = fieldElement.getParams().get("max");

        value = getValue(max);

        if (value != null) {
            field.setMax(value);
        }

        String precision = fieldElement.getParams().get("precision");

        value = getValue(precision);

        if (value != null) {
            field.setPrecision(value);
        }

        String step = fieldElement.getParams().get("step");

        value = getValue(step);

        if (value != null) {
            field.setStep(value);
        }
    }

}