红联Linux门户
Linux帮助

Hibernate Validator 5.1.0.CR1发布

发布时间:2014-02-19 09:49:24来源:红联作者:empast
Hibernate Validator 5.1.0.CR1 发布,此版本离最终版本又更近了一步,包括了一些调整和 bug 修复:

addressed issues with the CDI integration (HV-858)

EL message interpolation (HV-834)

validated value unwrapping in conjunction with Validator#validateValueandValidator#validateProperty(HV-860)

gave @Mod10Check and @Mod11Check a final overhaul and made the parameter naming more consistent and changed the semantics ofstartIndex,endIndexandcheckDigitIndex. They are now all inclusive and always relative to the original validated value, indepent ofignoreNonDigitCharacters. If you are already using these new constraints, I recommend you review the linked Javadocs to understand the updated semantics

Last but not least, we added yet another checksum related constraint -@EAN. It allows you to validate International Article Numbers (EAN-13 and EAN-8).

更多更新信息请看这里 ;Maven artefacts are on the JBoss Maven repository under the GAV org.hibernate:hibernate-validator:5.1.0.CR1 and distribution bundles are available on SourceForge.

Feedback and questions are always welcome via the Hibernate Validator forum or on stackoverflow using the hibernate-validator tag.

用Annotations 给类或者类的属性加上约束(constraint),在运行期检查属性值是很优雅的.Hibernate Validator就是这样的一个框架.该框架是十分容易的(就像参考文档中宣称的那样),几乎没有什么学习曲线,Validator 是一个验证框架 不需要和Hibernate的其他部分绑定就可以使用,只要在你的项目中添加Hibernate-annotations.jar库就可以了.

项目主页:https://hibernate.atlassian.net/secure/ReleaseNote.jspa?projectId=10060&version=15550

下载地址:http://sourceforge.net/projects/nhcontrib/files/

来自:开源中国社区
文章评论

共有 0 条评论