http://www.stripesframework.org/display/stripes/validation+reference#validationreferen...@validate%28expression%3d%22%24\%22%29

2010/9/7 Grzegorz Krugły <[email protected]>:
> Will it will be possible to change final variable's value?
>
>
> W dniu 07.09.2010 16:38, Samuel Santos pisze:
>
> I definitivly like the @ValidationMethod better, but you can do something
> like this:
>
> protected final int MAX_VALUE = 9999;
>
> @Validate(required = true, minvalue = 1900, maxvalue = MAX_VALUE)
> private int birthyear;
>
> {
>     MAX_VALUE = Calendar.getInstance().get(Calendar.YEAR);
> }
>
> or
>
> protected final int MAX_VALUE = 9999;
>
> @Validate(required = true, minvalue = 1900, maxvalue = MAX_VALUE)
> private int birthyear;
>
> public BaseActionBean() {
>     MAX_VALUE = Calendar.getInstance().get(Calendar.YEAR);
> }
>
>
> ------------------------------------------------------------------------------
> This SF.net Dev2Dev email is sponsored by:
>
> Show off your parallel programming skills.
> Enter the Intel(R) Threading Challenge 2010.
> http://p.sf.net/sfu/intel-thread-sfd
> _______________________________________________
> Stripes-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/stripes-users
>
>



-- 
Richard Hauswald
Blog: http://tnfstacc.blogspot.com/
LinkedIn: http://www.linkedin.com/in/richardhauswald
Xing: http://www.xing.com/profile/Richard_Hauswald

------------------------------------------------------------------------------
This SF.net Dev2Dev email is sponsored by:

Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd
_______________________________________________
Stripes-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-users

Reply via email to