Hi,
I am writing a tap 4 component and want to use the translated field support
to convert the user input to an integer.
However when I enter a numeric value into the field, the translator returns
a Long, and I get a class cast exception when try to set it to a value.
@Parameter(defaultValue = "translator:number")
public abstract Translator getTranslator();
InjectObject("service:tapestry.form.TranslatedFieldSupport")
public abstract TranslatedFieldSupport getTranslatedFieldSupport();
Integer dayInt = (Integer) getTranslatedFieldSupport().parse(this,
dayValue);
I had a look through the source but I couldnt find a way of specifing the
type of Number to return from the translator.
I am able to parse the input myself and everything works fine
Can anyone help?