Hi,

I'm currently struggling with porting a wicket 1.4 subclass of Localizer to
wicket 6. Here subclassing is prohibited by the final keyword.

===========================================================
public class MyLocalizer extends Localizer {

    @Override
    public String getStringIgnoreSettings( final String key, final
Component component, final IModel<?> model, final String defaultValue ) {

final boolean flag = Session.get().getFlag();
if (flag) {
return String.format("[%s]", key)
}

return super.getStringIgnoreSettings( key, component, model, defaultValue );
    }

}
===========================================================


As you can see, I simply want to return the key if a certain flag is set.
Is this somehow possible by using the IStringResourceLoader interface? Any
help is appreciated.

Thanks,
David

Reply via email to