You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Lukasz Lenart <lu...@apache.org> on 2012/10/11 21:51:32 UTC

Validator and parse param

Hi all!

I'm working on [1] and I've noticed that the ValidatorSupport class
already contains undocumented method conditionalParse(String). I've
used it to parse min/max values in Int validator [2] but it must be
enabled by specifying parse param. I'm wondering if we need that, why
not simple parse all the validator's params (as min/max), if there be
no expression, the param value will be returned.

[1] https://issues.apache.org/jira/browse/WW-2923
[2] https://cwiki.apache.org/confluence/display/WW/int+validator


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Validator and parse param

Posted by Lukasz Lenart <lu...@apache.org>.
2012/10/11 Lukasz Lenart <lu...@apache.org>:
> I'm working on [1] and I've noticed that the ValidatorSupport class
> already contains undocumented method conditionalParse(String). I've
> used it to parse min/max values in Int validator [2] but it must be
> enabled by specifying parse param. I'm wondering if we need that, why
> not simple parse all the validator's params (as min/max), if there be
> no expression, the param value will be returned.
>
> [1] https://issues.apache.org/jira/browse/WW-2923
> [2] https://cwiki.apache.org/confluence/display/WW/int+validator

As a follow up I've noticed that the annotations used to configure
validators are missing the parse param, so it works only for
validators configured via XML file. I'm going to remove the parse
param and allow to parse all the validator properties.


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org