Hi,

I had a deeper look at BVAL-214 (http://beanvalidation.org/proposals/BVAL-214/) and have some additional input. Since we depend on java 8 I think it would make sense to use suppliers to create the bean mocks for validation. This can look like this:

BeanValidator<ContactDataModel> contactValidator = BeanValidator.build(ContactDataModel.class);
contactValidator.withProperty("city", () -> cityField.getText()).
withProperty("zipCode", () -> zipCodeField.getText());

In addition I think that it will be important to have a better feedback for the violations that are based on a UI field. If you have a violation based in the text of the cityField you normally want to mark that field in the UI. I think a consumer can really help here:

contactValidator.withProperty("city", () -> cityField.getText(), v -> markCityField(v));
By doing so you will always get the set of violations that is based on the value in the city field.

You can find a first idea of such an interface and 2 view controller examples here: https://github.com/guigarage/validation-playground/tree/master/src/main/java/com/guigarage/dynamicvalidation

Cheers,

Hendrik



Am 01.09.2016 um 10:14 schrieb Gunnar Morling <gunnar@hibernate.org>:

Hi,

Unfortunately I won't be able to attend JavaOne myself, but still it should be a great opportunity for members of the BV EG and community to meet and exchange.

As per [1] there is a BV 2.0 Hackergarten event scheduled for Tuesday the 20th, led by Michael Nascimento. Thanks for taking this initiative, Michael!

Interesting things to discuss and explore might be proposals written by then (e.g. the one around List<@Email>, Emmanuel is working on updating this one) and things like ordering of constraints (BVAL-248, [2]) or David Blevins' proposal around using Lambdas (BVAL-515, [3]). David should be there, so make sure to get hold of him :)

Another interesting topic is integration with other specs/techs (e.g. javax.money or JavaFX). Specifically, there are several pending issues around the integration of BV and JAX-RS:

* Provides means to disable BV during JAX-RS lifecycle validation (BVAL-520, [4])
* Provide facility for more flexible HTTP error codes when using BV with JAX-RS (BVAL-518, [5])
* Pass the request locale to BV's MessageInterpolator

Mostly these things would have to be done on the JAX-RS side, so it would be great to have a chat with them if there is the chance for it.

Apart from that, essentially anything would be great which helps with forming a picture of the community's needs and requirements.

Thoughts?

Cheers,


_______________________________________________
beanvalidation-dev mailing list
beanvalidation-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/beanvalidation-dev