Re: Any mature work on integrating Hibernate Validator with Wicket?
Hey all, I had also created a JSR-303 integration solution as part of visural-wicket. It's not been fully documented yet w/ examples, but is fully functional and is a really handy addition. I planned to include/document it in the next release of visural-wicket (0.6). http://code.google.com/p/visural-wicket/source/browse/#svn/trunk/visural-wicket/src/com/visural/wicket/behavior/jsr303 There is a sample Form class to extend from to enable this functionality, but it is not mandatory. (see JSR303ValidatedForm.java#onBeforeRender() ... ) cheers, Rich On 12 April 2010 11:46, Ben Tilford bentilf...@gmail.com wrote: If you find anything useful heres some stuff I have put together https://docs.google.com/leaf?id=0ByQjVcAVDuP9MWE4NDcxODMtODZlOC00Mzk0LThhOTUtYmI2MmNlYzEwNWFihl=en I'd upload it somewhere else but it looks like there are already like 4 different projects for this. 2010/4/10 Uwe Schäfer u...@thomas-daily.de David Chang schrieb: hi, did you get the jsr 303 validation code released? where can i find it? i am really excited looking forward to it. about to. just finishing examples tomorrow. stay tuned. cu uwe - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Richard Nichols :: http://www.visural.com/ :: http://www.richardnichols.net/ - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
If you find anything useful heres some stuff I have put together https://docs.google.com/leaf?id=0ByQjVcAVDuP9MWE4NDcxODMtODZlOC00Mzk0LThhOTUtYmI2MmNlYzEwNWFihl=en I'd upload it somewhere else but it looks like there are already like 4 different projects for this. 2010/4/10 Uwe Schäfer u...@thomas-daily.de David Chang schrieb: hi, did you get the jsr 303 validation code released? where can i find it? i am really excited looking forward to it. about to. just finishing examples tomorrow. stay tuned. cu uwe - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
Carlos Vara schrieb: Seeing as it is only 2 simple classes, and that the external dependencies can be reduced to a minimum (just javax-validation-api) i think message resolution is flawed (i18n) and making wicket directly dependent from javax.validation might be a bad thing. cu uwe - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
hi, did you get the jsr 303 validation code released? where can i find it? i am really excited looking forward to it. all the best, david --- On Mon, 4/5/10, Uwe Schäfer u...@thomas-daily.de wrote: From: Uwe Schäfer u...@thomas-daily.de Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:08 AM David Chang schrieb: Any comment or pointers regarding relatively mature work in this regard? we did something that does not need spring, though it need some polishing and is not yet released. i´ll contact you later this week. cu uwe - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
David Chang schrieb: hi, did you get the jsr 303 validation code released? where can i find it? i am really excited looking forward to it. about to. just finishing examples tomorrow. stay tuned. cu uwe - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
David Chang schrieb: Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. i´d like to contribute my approach to wicketstuff-core. i do have commit access for wicketstuff. is there anyone to ask/any procedure to fulfill in order to create a new wicketstuff-core project ? cu uwe -- THOMAS DAILY GmbH Adlerstraße 19 79098 Freiburg Deutschland T + 49 761 3 85 59 0 F + 49 761 3 85 59 550 E schae...@thomas-daily.de www.thomas-daily.de Geschäftsführer/Managing Directors: Wendy Thomas, Susanne Larbig Handelsregister Freiburg i.Br., HRB 3947 Registrieren Sie sich unter http://www.signin.thomas-daily.de für die kostenfreien TD Morning News, eine Auswahl aktueller Themen des Tages morgens um 9:00 in Ihrer Mailbox. Hinweis: Der Redaktionsschluss für unsere TD Morning News ist täglich um 8:30 Uhr. Es werden vorrangig Informationen berücksichtigt, die nach 16:00 Uhr des Vortages eingegangen sind. Die Email-Adresse unserer Redaktion lautet redakt...@thomas-daily.de. To receive the free TD News International – a selection of the day’s top issues delivered to your mail box every day – please register at www.signin.thomas-daily.de Please note: Information received for our TD News International after 4 p.m. will be given priority for publication the following day. The daily editorial deadline is 8:30 a.m. You can reach our editorial staff at redakt...@thomas-daily.de. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
nope - just have at it -- Jeremy Thomerson http://www.wickettraining.com 2010/4/9 Uwe Schäfer schae...@thomas-daily.de David Chang schrieb: Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. i´d like to contribute my approach to wicketstuff-core. i do have commit access for wicketstuff. is there anyone to ask/any procedure to fulfill in order to create a new wicketstuff-core project ? cu uwe -- THOMAS DAILY GmbH Adlerstraße 19 79098 Freiburg Deutschland T + 49 761 3 85 59 0 F + 49 761 3 85 59 550 E schae...@thomas-daily.de www.thomas-daily.de Geschäftsführer/Managing Directors: Wendy Thomas, Susanne Larbig Handelsregister Freiburg i.Br., HRB 3947 Registrieren Sie sich unter http://www.signin.thomas-daily.de für die kostenfreien TD Morning News, eine Auswahl aktueller Themen des Tages morgens um 9:00 in Ihrer Mailbox. Hinweis: Der Redaktionsschluss für unsere TD Morning News ist täglich um 8:30 Uhr. Es werden vorrangig Informationen berücksichtigt, die nach 16:00 Uhr des Vortages eingegangen sind. Die Email-Adresse unserer Redaktion lautet redakt...@thomas-daily.de. To receive the free TD News International – a selection of the day’s top issues delivered to your mail box every day – please register at www.signin.thomas-daily.de Please note: Information received for our TD News International after 4 p.m. will be given priority for publication the following day. The daily editorial deadline is 8:30 a.m. You can reach our editorial staff at redakt...@thomas-daily.de. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
Hi David, The code may be simple, but the idea/benefits I see may be great. Wouldn't be better to make it available on wicketstuff in good shape instead of me or others googling it out? :) Just my 2 cents. I totally agree with you here. I find JSR-303 to be a great standard that addresses the validation problem very well, so having a minimal start point inside wicket to use it would be a good idea. Seeing as it is only 2 simple classes, and that the external dependencies can be reduced to a minimum (just javax-validation-api), I proposed a RFE in wickets jira: https://issues.apache.org/jira/browse/WICKET-2825 Vote for it if you like the idea :-) Regards, David --- On Mon, 4/5/10, Carlos Vara bashfl...@gmail.com wrote: From: Carlos Vara bashfl...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 4:52 PM Hi David, I'm the author of the first article that you linked to: http://carinae.net/tag/hibernate-validator/ http://carinae.net/2009/12/integration-of-jsr-303-bean-validation-standard-and-wicket-1-4/ Basically, you hardly need more than the two provided validators (for property validation on field input, and full bean validation on form input). I added some extra code to integrate it with Spring and to centralize the locale, but if you don't need it, you can easily use only those validators without anything else. The way I see it, there is no code in wicketstuff because it is quite simple to integrate jsr303 and wicket, so picking the code from my or others blog, and maybe tweaking it a little for your needs is probably all you need. On Mon, Apr 5, 2010 at 9:39 PM, Ben Tilford bentilf...@gmail.com wrote: So far this is what I've got. Doesn't do anything with groups or the more advanced stuff but this may be all it takes. public class BeanComponentValidatorT extends AbstractValidatorT { public BeanComponentValidator() { super(); } @Override protected void onValidate(IValidatableT validatable) { for(ConstraintViolationT violation : validate(validatable.getValue())) { validatable.error(new ValidationError().addMessageKey(violation.getMessage())); } } SetConstraintViolationT validate(T value) { Validator validator = Validation.buildDefaultValidatorFactory().getValidator();//this may only be working because I'm using Spring 3.0.2 and Hibernate 3.5 I don't know for sure. return validator.validate(value); } } On Mon, Apr 5, 2010 at 12:15 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: Hi! It's quite easy to add trivial min/max/required validators using (any) helper method. Maybe bindgen project would be closest to this.. it's already working with annotations, it could perhaps parse also annotations of property target objects. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: Using Hibernate Validator may bring a few good things: 1. On the data end, it helps to improve data, performance, etc. Also the annotation you write on domain objects get translated into database creation and objects save/update. You can find more on in this area. Obviously, this has nothing to do with wicket. 2. Regarding the web tier, it is often needed to write validation rules such as not null or the maximum chars in an input field being less than 10. In pure wicket, you have to add many validation rules yourself manually for each field. Why should I do so second time in wicket if I can explicitly specify them on domain objects via Hibernate Validator (or Bean Validation, JSR 303, now official)? I hope to see wicket can take adavantage of bean validation to let us code faster and have more maintainable code. Please feel free to comment I am wrong. Best. --- On Mon, 4/5/10, Martin Makundi martin.maku...@koodaripalvelut.com wrote: From: Martin Makundi martin.maku...@koodaripalvelut.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:31 AM Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether
Re: Any mature work on integrating Hibernate Validator with Wicket?
Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
David Chang schrieb: Any comment or pointers regarding relatively mature work in this regard? we did something that does not need spring, though it need some polishing and is not yet released. i´ll contact you later this week. cu uwe - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
so if somebody took the code from the blogs and put them on a project in wicketstuff that would make it more mature? there is not much to integrating the validators with wicket so each project probably built out their own way to do it that suits that project. -igor On Mon, Apr 5, 2010 at 8:27 AM, David Chang david_q_zh...@yahoo.com wrote: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
Using Hibernate Validator may bring a few good things: 1. On the data end, it helps to improve data, performance, etc. Also the annotation you write on domain objects get translated into database creation and objects save/update. You can find more on in this area. Obviously, this has nothing to do with wicket. 2. Regarding the web tier, it is often needed to write validation rules such as not null or the maximum chars in an input field being less than 10. In pure wicket, you have to add many validation rules yourself manually for each field. Why should I do so second time in wicket if I can explicitly specify them on domain objects via Hibernate Validator (or Bean Validation, JSR 303, now official)? I hope to see wicket can take adavantage of bean validation to let us code faster and have more maintainable code. Please feel free to comment I am wrong. Best. --- On Mon, 4/5/10, Martin Makundi martin.maku...@koodaripalvelut.com wrote: From: Martin Makundi martin.maku...@koodaripalvelut.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:31 AM Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe
Re: Any mature work on integrating Hibernate Validator with Wicket?
so if somebody took the code from the blogs and put them on a project in wicketstuff that would make it more mature? I dont think so. wicketstuff is just one place to look at. But I dont think people would put their blogs there. Yes, they can. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:35 AM so if somebody took the code from the blogs and put them on a project in wicketstuff that would make it more mature? there is not much to integrating the validators with wicket so each project probably built out their own way to do it that suits that project. -igor On Mon, Apr 5, 2010 at 8:27 AM, David Chang david_q_zh...@yahoo.com wrote: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Any mature work on integrating Hibernate Validator with Wicket?
Hi! It's quite easy to add trivial min/max/required validators using (any) helper method. Maybe bindgen project would be closest to this.. it's already working with annotations, it could perhaps parse also annotations of property target objects. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: Using Hibernate Validator may bring a few good things: 1. On the data end, it helps to improve data, performance, etc. Also the annotation you write on domain objects get translated into database creation and objects save/update. You can find more on in this area. Obviously, this has nothing to do with wicket. 2. Regarding the web tier, it is often needed to write validation rules such as not null or the maximum chars in an input field being less than 10. In pure wicket, you have to add many validation rules yourself manually for each field. Why should I do so second time in wicket if I can explicitly specify them on domain objects via Hibernate Validator (or Bean Validation, JSR 303, now official)? I hope to see wicket can take adavantage of bean validation to let us code faster and have more maintainable code. Please feel free to comment I am wrong. Best. --- On Mon, 4/5/10, Martin Makundi martin.maku...@koodaripalvelut.com wrote: From: Martin Makundi martin.maku...@koodaripalvelut.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:31 AM Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h
Re: Any mature work on integrating Hibernate Validator with Wicket?
So far this is what I've got. Doesn't do anything with groups or the more advanced stuff but this may be all it takes. public class BeanComponentValidatorT extends AbstractValidatorT { public BeanComponentValidator() { super(); } @Override protected void onValidate(IValidatableT validatable) { for(ConstraintViolationT violation : validate(validatable.getValue())) { validatable.error(new ValidationError().addMessageKey(violation.getMessage())); } } SetConstraintViolationT validate(T value) { Validator validator = Validation.buildDefaultValidatorFactory().getValidator();//this may only be working because I'm using Spring 3.0.2 and Hibernate 3.5 I don't know for sure. return validator.validate(value); } } On Mon, Apr 5, 2010 at 12:15 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: Hi! It's quite easy to add trivial min/max/required validators using (any) helper method. Maybe bindgen project would be closest to this.. it's already working with annotations, it could perhaps parse also annotations of property target objects. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: Using Hibernate Validator may bring a few good things: 1. On the data end, it helps to improve data, performance, etc. Also the annotation you write on domain objects get translated into database creation and objects save/update. You can find more on in this area. Obviously, this has nothing to do with wicket. 2. Regarding the web tier, it is often needed to write validation rules such as not null or the maximum chars in an input field being less than 10. In pure wicket, you have to add many validation rules yourself manually for each field. Why should I do so second time in wicket if I can explicitly specify them on domain objects via Hibernate Validator (or Bean Validation, JSR 303, now official)? I hope to see wicket can take adavantage of bean validation to let us code faster and have more maintainable code. Please feel free to comment I am wrong. Best. --- On Mon, 4/5/10, Martin Makundi martin.maku...@koodaripalvelut.com wrote: From: Martin Makundi martin.maku...@koodaripalvelut.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:31 AM Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Sunday, April 4, 2010, 11:31 PM Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter
Re: Any mature work on integrating Hibernate Validator with Wicket?
Hi David, I'm the author of the first article that you linked to: http://carinae.net/tag/hibernate-validator/ http://carinae.net/2009/12/integration-of-jsr-303-bean-validation-standard-and-wicket-1-4/Basically, you hardly need more than the two provided validators (for property validation on field input, and full bean validation on form input). I added some extra code to integrate it with Spring and to centralize the locale, but if you don't need it, you can easily use only those validators without anything else. The way I see it, there is no code in wicketstuff because it is quite simple to integrate jsr303 and wicket, so picking the code from my or others blog, and maybe tweaking it a little for your needs is probably all you need. On Mon, Apr 5, 2010 at 9:39 PM, Ben Tilford bentilf...@gmail.com wrote: So far this is what I've got. Doesn't do anything with groups or the more advanced stuff but this may be all it takes. public class BeanComponentValidatorT extends AbstractValidatorT { public BeanComponentValidator() { super(); } @Override protected void onValidate(IValidatableT validatable) { for(ConstraintViolationT violation : validate(validatable.getValue())) { validatable.error(new ValidationError().addMessageKey(violation.getMessage())); } } SetConstraintViolationT validate(T value) { Validator validator = Validation.buildDefaultValidatorFactory().getValidator();//this may only be working because I'm using Spring 3.0.2 and Hibernate 3.5 I don't know for sure. return validator.validate(value); } } On Mon, Apr 5, 2010 at 12:15 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: Hi! It's quite easy to add trivial min/max/required validators using (any) helper method. Maybe bindgen project would be closest to this.. it's already working with annotations, it could perhaps parse also annotations of property target objects. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: Using Hibernate Validator may bring a few good things: 1. On the data end, it helps to improve data, performance, etc. Also the annotation you write on domain objects get translated into database creation and objects save/update. You can find more on in this area. Obviously, this has nothing to do with wicket. 2. Regarding the web tier, it is often needed to write validation rules such as not null or the maximum chars in an input field being less than 10. In pure wicket, you have to add many validation rules yourself manually for each field. Why should I do so second time in wicket if I can explicitly specify them on domain objects via Hibernate Validator (or Bean Validation, JSR 303, now official)? I hope to see wicket can take adavantage of bean validation to let us code faster and have more maintainable code. Please feel free to comment I am wrong. Best. --- On Mon, 4/5/10, Martin Makundi martin.maku...@koodaripalvelut.com wrote: From: Martin Makundi martin.maku...@koodaripalvelut.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:31 AM Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users
Re: Any mature work on integrating Hibernate Validator with Wicket?
Ben, Thanks for sharing your code, which, IMHO, definately helps not only me but also others. I believe that using Hibernate Validator really kills more than one bird in one stone. All the best, David P.S. folks, please feel free to comment how you feel about the Bean Validation/Hiberate Validator thing. Just wanted to do the right/good thing for me and everybody. There might be cases where using Hibernate Validator will not be helpful or bad. Please feel free to let us know if you can think of them. --- On Mon, 4/5/10, Ben Tilford bentilf...@gmail.com wrote: From: Ben Tilford bentilf...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 3:39 PM So far this is what I've got. Doesn't do anything with groups or the more advanced stuff but this may be all it takes. public class BeanComponentValidatorT extends AbstractValidatorT { public BeanComponentValidator() { super(); } @Override protected void onValidate(IValidatableT validatable) { for(ConstraintViolationT violation : validate(validatable.getValue())) { validatable.error(new ValidationError().addMessageKey(violation.getMessage())); } } SetConstraintViolationT validate(T value) { Validator validator = Validation.buildDefaultValidatorFactory().getValidator();//this may only be working because I'm using Spring 3.0.2 and Hibernate 3.5 I don't know for sure. return validator.validate(value); } } On Mon, Apr 5, 2010 at 12:15 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: Hi! It's quite easy to add trivial min/max/required validators using (any) helper method. Maybe bindgen project would be closest to this.. it's already working with annotations, it could perhaps parse also annotations of property target objects. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: Using Hibernate Validator may bring a few good things: 1. On the data end, it helps to improve data, performance, etc. Also the annotation you write on domain objects get translated into database creation and objects save/update. You can find more on in this area. Obviously, this has nothing to do with wicket. 2. Regarding the web tier, it is often needed to write validation rules such as not null or the maximum chars in an input field being less than 10. In pure wicket, you have to add many validation rules yourself manually for each field. Why should I do so second time in wicket if I can explicitly specify them on domain objects via Hibernate Validator (or Bean Validation, JSR 303, now official)? I hope to see wicket can take adavantage of bean validation to let us code faster and have more maintainable code. Please feel free to comment I am wrong. Best. --- On Mon, 4/5/10, Martin Makundi martin.maku...@koodaripalvelut.com wrote: From: Martin Makundi martin.maku...@koodaripalvelut.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:31 AM Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:21 AM you have answered your own question twice, why does anyone else need to reply? -igor On Mon, Apr 5, 2010 at 8:01 AM, David Chang david_q_zh...@yahoo.com wrote: Hi folks, I feel a bit puzzled about not getting any response on this topic. I have to say that I am new in Wicket. If this a bad or wrong question or if this is something not worthy to explore, please feel free to let me know. Thanks for any input! --- On Sun, 4/4/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users
Re: Any mature work on integrating Hibernate Validator with Wicket?
Carlos, Thanks for chiming in and for good work and sharing! so picking the code from my or others blog, The code may be simple, but the idea/benefits I see may be great. Wouldn't be better to make it available on wicketstuff in good shape instead of me or others googling it out? :) Just my 2 cents. Regards, David --- On Mon, 4/5/10, Carlos Vara bashfl...@gmail.com wrote: From: Carlos Vara bashfl...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 4:52 PM Hi David, I'm the author of the first article that you linked to: http://carinae.net/tag/hibernate-validator/ http://carinae.net/2009/12/integration-of-jsr-303-bean-validation-standard-and-wicket-1-4/Basically, you hardly need more than the two provided validators (for property validation on field input, and full bean validation on form input). I added some extra code to integrate it with Spring and to centralize the locale, but if you don't need it, you can easily use only those validators without anything else. The way I see it, there is no code in wicketstuff because it is quite simple to integrate jsr303 and wicket, so picking the code from my or others blog, and maybe tweaking it a little for your needs is probably all you need. On Mon, Apr 5, 2010 at 9:39 PM, Ben Tilford bentilf...@gmail.com wrote: So far this is what I've got. Doesn't do anything with groups or the more advanced stuff but this may be all it takes. public class BeanComponentValidatorT extends AbstractValidatorT { public BeanComponentValidator() { super(); } @Override protected void onValidate(IValidatableT validatable) { for(ConstraintViolationT violation : validate(validatable.getValue())) { validatable.error(new ValidationError().addMessageKey(violation.getMessage())); } } SetConstraintViolationT validate(T value) { Validator validator = Validation.buildDefaultValidatorFactory().getValidator();//this may only be working because I'm using Spring 3.0.2 and Hibernate 3.5 I don't know for sure. return validator.validate(value); } } On Mon, Apr 5, 2010 at 12:15 PM, Martin Makundi martin.maku...@koodaripalvelut.com wrote: Hi! It's quite easy to add trivial min/max/required validators using (any) helper method. Maybe bindgen project would be closest to this.. it's already working with annotations, it could perhaps parse also annotations of property target objects. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: Using Hibernate Validator may bring a few good things: 1. On the data end, it helps to improve data, performance, etc. Also the annotation you write on domain objects get translated into database creation and objects save/update. You can find more on in this area. Obviously, this has nothing to do with wicket. 2. Regarding the web tier, it is often needed to write validation rules such as not null or the maximum chars in an input field being less than 10. In pure wicket, you have to add many validation rules yourself manually for each field. Why should I do so second time in wicket if I can explicitly specify them on domain objects via Hibernate Validator (or Bean Validation, JSR 303, now official)? I hope to see wicket can take adavantage of bean validation to let us code faster and have more maintainable code. Please feel free to comment I am wrong. Best. --- On Mon, 4/5/10, Martin Makundi martin.maku...@koodaripalvelut.com wrote: From: Martin Makundi martin.maku...@koodaripalvelut.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010, 11:31 AM Do you have any user stories on the topic? It would be useful to evaluate how interesting the use case is. Me myself I cannot immagine anything useful could come out of hibernate validators, only something very trivial. Could be wrong, thoug. ** Martin 2010/4/5 David Chang david_q_zh...@yahoo.com: thanks for chiming in. sorry if i was not clear in prevoius posts. i would like to hear comments whether it is worthy to explore or any benefits. i also would like to know whether there is more mature work since i only found experimental work. i am unable to find anything aobut it on wicketstuff. regards. --- On Mon, 4/5/10, Igor Vaynberg igor.vaynb...@gmail.com wrote: From: Igor Vaynberg igor.vaynb...@gmail.com Subject: Re: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Monday, April 5, 2010
Re: Any mature work on integrating Hibernate Validator with Wicket?
Found another related work. http://42lines.net/content/integrating-hibernate-validator-and-wicket Any comment or pointers regarding relatively mature work in this regard? Regards. --- On Sat, 4/3/10, David Chang david_q_zh...@yahoo.com wrote: From: David Chang david_q_zh...@yahoo.com Subject: Any mature work on integrating Hibernate Validator with Wicket? To: users@wicket.apache.org Date: Saturday, April 3, 2010, 1:45 PM Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Any mature work on integrating Hibernate Validator with Wicket?
Is there any mature work on integrating Hibernate Validator with Wicket? I am unable to find any at wicketstuff. Googled and found this work is interesting. http://carinae.net/tag/hibernate-validator/ Any pointers? Any comment? Thanks and Happy Easter! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org