-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Validation annotations should be able to reference fields
PostPosted: Wed May 04, 2011 4:09 pm 
Newbie

Joined: Wed May 04, 2011 3:50 pm
Posts: 1
There are several typical cases for this including: Verifying a password, checking validity of a date range, etc. There are several proposed solutions, but they all involve either a large amount of code, or are not repeatable. For example: http://stackoverflow.com/questions/1972 ... or-jsr-303

Rather than having to build annotations on top of the class, I would love support for something like:

public class SignupForm{

@NotNull
String password;

@NotNull
@Confirms(confirm="password")
String passwordConfirmation;
}

Weather as a builtin, or given the ability to construct our own - this would be extremely handy!


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.