[hibernate-issues] [Hibernate-JIRA] Created: (HV-487) Settle on an approach for instantiating constraint definitions
Gunnar Morling (JIRA)
noreply at atlassian.com
Wed Jun 8 15:15:25 EDT 2011
Settle on an approach for instantiating constraint definitions
--------------------------------------------------------------
Key: HV-487
URL: http://opensource.atlassian.com/projects/hibernate/browse/HV-487
Project: Hibernate Validator
Issue Type: Task
Components: engine
Reporter: Gunnar Morling
Fix For: 4.2.0.Final
Due to the addition of method constraints the completely fluent way for instantiating constraint definitions in the mapping API doesn't work anymore. The alternatives discussed so far include:
(1):
{code:java}
mapping.type( Marathon.class )
.property( "name", METHOD )
.constraint( new NotNullDef() )
{code}
(2):
{code:java}
mapping.type( Marathon.class )
.property( "name", METHOD )
.constraint( ConstraintDef.create( NotNullDef.class ) )
{code}
(3):
{code:java}
mapping.type( Marathon.class )
.property( "name", METHOD )
.constraint( NotNullDef.create() )
{code}
One approach must be chosen and implemented (as of HV-431 (2) is implemented).
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list