[hibernate-commits] Hibernate SVN: r16155 - in validator/trunk/hibernate-validator: src/main/java/org/hibernate/validation/engine and 1 other directory.

hibernate-commits at lists.jboss.org hibernate-commits at lists.jboss.org
Fri Mar 13 05:27:15 EDT 2009


Author: hardy.ferentschik
Date: 2009-03-13 05:27:14 -0400 (Fri, 13 Mar 2009)
New Revision: 16155

Modified:
   validator/trunk/hibernate-validator/pom.xml
   validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintTree.java
Log:
Now jtype is relocated to org.hibernate.validation.jtype using the share plugin. Relocation will prevent class conflicts in case another version of jtype is in the classpath.

Modified: validator/trunk/hibernate-validator/pom.xml
===================================================================
--- validator/trunk/hibernate-validator/pom.xml	2009-03-13 09:00:59 UTC (rev 16154)
+++ validator/trunk/hibernate-validator/pom.xml	2009-03-13 09:27:14 UTC (rev 16155)
@@ -86,6 +86,12 @@
                                     <include>com.googlecode.jtype:jtype</include>
                                 </includes>
                             </artifactSet>
+                            <relocations>
+                                <relocation>
+                                    <pattern>com.googlecode.jtype</pattern>
+                                    <shadedPattern>org.hibernate.validation.jtype</shadedPattern>
+                                </relocation>
+                            </relocations>
                             <transformers>
                                 <transformer implementation="org.apache.maven.plugins.shade.resource.ComponentsXmlResourceTransformer"/>
                             </transformers>

Modified: validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintTree.java
===================================================================
--- validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintTree.java	2009-03-13 09:00:59 UTC (rev 16154)
+++ validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintTree.java	2009-03-13 09:27:14 UTC (rev 16155)
@@ -162,6 +162,8 @@
 
 		List<Type> suitableTypes = new ArrayList<Type>();
 		findSuitableValidatorTypes( type, validatorsTypes, suitableTypes );
+		// TODO - do we really have to take the actual value into consideration here as well? Or is it enough to
+		// work with the type the constraint was placed on?
 		if ( value != null ) {
 			findSuitableValidatorTypes( determineValueClass( value ), validatorsTypes, suitableTypes );
 		}




More information about the hibernate-commits mailing list