-
Sep 27th, 2010, 09:50 AM
#1
@Expression condition
Hi,
unfortunely my application is still using old spring-mod 0.9.2, I hope it's okay this forum for my post:
I have a bean with these 2 fields and relative annotations:
@Expression(value="total > 0 and total < 4", applyIf="sportType EQUALS ['org.demo.SportType.FOOTBALL']")
private Integer total;
@NotNull
protected SportType sportType;
main problem is about the @Expression:
org.springmodules.validation.util.cel.CelParseExce ption: Could not parse valang expression 'sportType EQUALS ['org.demo.SportType.FOOTBALL']'; nested exception is org.springmodules.validation.valang.parser.ParseEx ception: Could not parse date ['org.demo.SportType.FOOTBALL'] at line 1, column 24.
basically I'm trying to express this:
if (sportType equals FOOTBALL) then check if 0<total<4
how can I do that correctly via annotations?
Thanks,
Julio
-
Feb 17th, 2011, 06:59 PM
#2
Thank you so much for your post.
__________________
Watch Unknown Online Free
-
Mar 17th, 2011, 08:07 PM
#3
Hallo, schön dich zu treffen! Ich zum ersten Mal diese Art von Forum, in der Hoffnung, zu einem späteren Zeitpunkt werden Ihre Führer! ! ! Vielen Dank! ! ! ! !
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules