Author: epbernard
Date: 2009-06-15 14:03:30 -0400 (Mon, 15 Jun 2009)
New Revision: 16788
Added:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/BeanDescriptor.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ConstraintDescriptor.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ElementDescriptor.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/PropertyDescriptor.java
Removed:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/BeanDescriptor.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintDescriptor.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ElementDescriptor.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/PropertyDescriptor.java
Modified:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintViolation.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/MessageInterpolator.java
beanvalidation/trunk/validation-api/src/main/java/javax/validation/Validator.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanDescriptorImpl.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaData.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaDataImpl.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintDescriptorImpl.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintTree.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintValidatorContextImpl.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintViolationImpl.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ElementDescriptorImpl.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ExecutionContext.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MessageInterpolatorContext.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MetaConstraint.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/PropertyDescriptorImpl.java
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ValidatorImpl.java
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/constraints/custom/CustomConstraintValidatorTest.java
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/ValidatorImplTest.java
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/groups/GroupTest.java
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/inheritance/InheritanceTest.java
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/util/TestUtil.java
Log:
Move metadata classes to the metadata package (BeanDescriptor, ElementDescriptor,
PropertyDescriptor, ConstraintDescriptor)
Deleted:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/BeanDescriptor.java
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/BeanDescriptor.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/BeanDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -1,59 +0,0 @@
-// $Id$
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.validation;
-
-import java.util.Set;
-
-/**
- * Describe a constrained Java Bean and the constraints associated to it.
- *
- * @author Emmanuel Bernard
- */
-public interface BeanDescriptor extends ElementDescriptor {
- /**
- * Returns true if the bean involves validation:
- * <ul>
- * <li> a constraint is hosted on the bean itself </li>
- * <li> a constraint is hosted on one of the bean properties </li>
- * <li> or a bean property is marked for cascade (@Valid) </li>
- * </ul>
- *
- * @return <code>true</code> if the bean involves validation,
<code>false</code> otherwise.
- */
- boolean isBeanConstrained();
-
- /**
- * Return the property descriptor for a given property.
- * Return <code>null</code> if the property does not exist or has no
- * constraint nor is marked as cascaded (see {@link #getConstrainedProperties()} )
- * <p/>
- * The returned object (and associated objects including ConstraintDescriptors)
- * are immutable.
- *
- * @param propertyName property evaludated
- *
- * @return the property descriptor for a given property.
- */
- PropertyDescriptor getConstraintsForProperty(String propertyName);
-
- /**
- * @return the property descriptors having at least one constraint defined or which are
marked
- * as cascaded (@Valid) or an empty set.
- */
- Set<PropertyDescriptor> getConstrainedProperties();
-}
Deleted:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintDescriptor.java
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintDescriptor.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -1,85 +0,0 @@
-// $Id$
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.validation;
-
-import java.lang.annotation.Annotation;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * Describes a single constraint and its composing constraints.
- * T is the constraint's annotation type.
- *
- * @author Emmanuel Bernard
- * @author Hardy Ferentschik
- */
-public interface ConstraintDescriptor<T extends Annotation> {
- /**
- * Returns the annotation describing the constraint declaration.
- * If a composing constraint, attribute values are reflecting
- * the overridden attributes of the composing constraint
- *
- * @return The annotation for this constraint.
- */
- T getAnnotation();
-
- /**
- * The Set of groups the constraint is applied on.
- * If the constraint declares no group, a set with only the
<code>Default</code>
- * group is returned.
- *
- * @return The groups the constraint is applied on.
- */
- Set<Class<?>> getGroups();
-
- /**
- * Immutable list of the constraint validation implementation classes.
- *
- * @return list of the constraint validation implementation classes.
- */
- List<Class<? extends ConstraintValidator<T, ?>>>
- getConstraintValidatorClasses();
-
- /**
- * Returns a map containing the annotation attribute names as keys and the
- * annotation attribute values as value.
- * If this constraint is used as part of a composed constraint, attribute
- * values are reflecting the overridden attribute of the composing constraint.
- *
- * @return a map containing the annotation attribute names as keys
- * and the annotation attribute values as value.
- */
- Map<String, Object> getAttributes();
-
- /**
- * Return a set of composing <code>ConstraintDescriptor</code>s where each
- * descriptor describes a composing constraint.
<code>ConstraintDescriptor</code>
- * instances of composing constraints reflect overridden attribute values in
- * {@link #getAttributes()} and {@link #getAnnotation()}.
- *
- * @return a set of <code>ConstraintDescriptor<code> objects or an empty
set
- * in case there are no composing constraints.
- */
- Set<ConstraintDescriptor<?>> getComposingConstraints();
-
- /**
- * @return true if the constraint is annotated with @ReportAsSingleViolation
- */
- boolean isReportAsSingleViolation();
-}
\ No newline at end of file
Modified:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintViolation.java
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintViolation.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintViolation.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -17,7 +17,7 @@
*/
package javax.validation;
-import java.util.Set;
+import javax.validation.metadata.ConstraintDescriptor;
/**
* Describe a constraint violation. This object describe the error context as
Deleted:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ElementDescriptor.java
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ElementDescriptor.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ElementDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -1,49 +0,0 @@
-// $Id$
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-package javax.validation;
-
-import java.util.Set;
-
-/**
- * Describes a validated element (class, field or property).
- *
- * @author Emmanuel Bernard
- * @author Hardy Ferentschik
- */
-public interface ElementDescriptor {
-
- /**
- * @return <code>true</code> if at least one constraint declaration is
present on the element, <code>false</code> otherwise.
- */
- boolean hasConstraints();
-
- /**
- * @return Statically defined returned type.
- *
- * @todo should it be Type or even completly removed
- */
- Class<?> getType();
-
- /**
- * Return all constraint descriptors for this element or an
- * empty Set if none are present.
- *
- * @return Set of constraint descriptors for this element
- */
- Set<ConstraintDescriptor<?>> getConstraintDescriptors();
-}
Modified:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/MessageInterpolator.java
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/MessageInterpolator.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/MessageInterpolator.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -18,6 +18,7 @@
package javax.validation;
import java.util.Locale;
+import javax.validation.metadata.ConstraintDescriptor;
/**
* Interpolate a given constraint error message.
Deleted:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/PropertyDescriptor.java
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/PropertyDescriptor.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/PropertyDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -1,23 +0,0 @@
-package javax.validation;
-
-/**
- * Describes a Java Bean property hosting validation constraints.
- *
- * Constraints placed on the attribute and the getter of a given property
- * are all referenced by this object.
- *
- * @author Emmanuel Bernard
- */
-public interface PropertyDescriptor extends ElementDescriptor {
- /**
- * Is the property marked by the <code>@Valid</code> annotation.
- * @return <code>true</code> if the annotation is present,
<code>false</code> otherwise.
- */
- boolean isCascaded();
-
- /**
- * Name of the property acording to the Java Bean specification.
- * @return property name.
- */
- String getPropertyName();
-}
\ No newline at end of file
Modified:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/Validator.java
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/Validator.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/Validator.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -18,6 +18,7 @@
package javax.validation;
import java.util.Set;
+import javax.validation.metadata.BeanDescriptor;
/**
* Validate bean instances. Implementations of this interface must be thread-safe.
Copied:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/BeanDescriptor.java
(from rev 16786,
beanvalidation/trunk/validation-api/src/main/java/javax/validation/BeanDescriptor.java)
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/BeanDescriptor.java
(rev 0)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/BeanDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -0,0 +1,59 @@
+// $Id$
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+package javax.validation.metadata;
+
+import java.util.Set;
+
+/**
+ * Describe a constrained Java Bean and the constraints associated to it.
+ *
+ * @author Emmanuel Bernard
+ */
+public interface BeanDescriptor extends ElementDescriptor {
+ /**
+ * Returns true if the bean involves validation:
+ * <ul>
+ * <li> a constraint is hosted on the bean itself </li>
+ * <li> a constraint is hosted on one of the bean properties </li>
+ * <li> or a bean property is marked for cascade (@Valid) </li>
+ * </ul>
+ *
+ * @return <code>true</code> if the bean involves validation,
<code>false</code> otherwise.
+ */
+ boolean isBeanConstrained();
+
+ /**
+ * Return the property descriptor for a given property.
+ * Return <code>null</code> if the property does not exist or has no
+ * constraint nor is marked as cascaded (see {@link #getConstrainedProperties()} )
+ * <p/>
+ * The returned object (and associated objects including ConstraintDescriptors)
+ * are immutable.
+ *
+ * @param propertyName property evaludated
+ *
+ * @return the property descriptor for a given property.
+ */
+ PropertyDescriptor getConstraintsForProperty(String propertyName);
+
+ /**
+ * @return the property descriptors having at least one constraint defined or which are
marked
+ * as cascaded (@Valid) or an empty set.
+ */
+ Set<PropertyDescriptor> getConstrainedProperties();
+}
Property changes on:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/BeanDescriptor.java
___________________________________________________________________
Name: svn:keywords
+ Id
Copied:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ConstraintDescriptor.java
(from rev 16786,
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ConstraintDescriptor.java)
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ConstraintDescriptor.java
(rev 0)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ConstraintDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -0,0 +1,86 @@
+// $Id$
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+package javax.validation.metadata;
+
+import java.lang.annotation.Annotation;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import javax.validation.ConstraintValidator;
+
+/**
+ * Describes a single constraint and its composing constraints.
+ * T is the constraint's annotation type.
+ *
+ * @author Emmanuel Bernard
+ * @author Hardy Ferentschik
+ */
+public interface ConstraintDescriptor<T extends Annotation> {
+ /**
+ * Returns the annotation describing the constraint declaration.
+ * If a composing constraint, attribute values are reflecting
+ * the overridden attributes of the composing constraint
+ *
+ * @return The annotation for this constraint.
+ */
+ T getAnnotation();
+
+ /**
+ * The Set of groups the constraint is applied on.
+ * If the constraint declares no group, a set with only the
<code>Default</code>
+ * group is returned.
+ *
+ * @return The groups the constraint is applied on.
+ */
+ Set<Class<?>> getGroups();
+
+ /**
+ * Immutable list of the constraint validation implementation classes.
+ *
+ * @return list of the constraint validation implementation classes.
+ */
+ List<Class<? extends ConstraintValidator<T, ?>>>
+ getConstraintValidatorClasses();
+
+ /**
+ * Returns a map containing the annotation attribute names as keys and the
+ * annotation attribute values as value.
+ * If this constraint is used as part of a composed constraint, attribute
+ * values are reflecting the overridden attribute of the composing constraint.
+ *
+ * @return a map containing the annotation attribute names as keys
+ * and the annotation attribute values as value.
+ */
+ Map<String, Object> getAttributes();
+
+ /**
+ * Return a set of composing <code>ConstraintDescriptor</code>s where each
+ * descriptor describes a composing constraint.
<code>ConstraintDescriptor</code>
+ * instances of composing constraints reflect overridden attribute values in
+ * {@link #getAttributes()} and {@link #getAnnotation()}.
+ *
+ * @return a set of <code>ConstraintDescriptor<code> objects or an empty
set
+ * in case there are no composing constraints.
+ */
+ Set<ConstraintDescriptor<?>> getComposingConstraints();
+
+ /**
+ * @return true if the constraint is annotated with @ReportAsSingleViolation
+ */
+ boolean isReportAsSingleViolation();
+}
\ No newline at end of file
Property changes on:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ConstraintDescriptor.java
___________________________________________________________________
Name: svn:keywords
+ Id
Copied:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ElementDescriptor.java
(from rev 16786,
beanvalidation/trunk/validation-api/src/main/java/javax/validation/ElementDescriptor.java)
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ElementDescriptor.java
(rev 0)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ElementDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -0,0 +1,49 @@
+// $Id$
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2008, Red Hat Middleware LLC, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
http://www.apache.org/licenses/LICENSE-2.0
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+package javax.validation.metadata;
+
+import java.util.Set;
+
+/**
+ * Describes a validated element (class, field or property).
+ *
+ * @author Emmanuel Bernard
+ * @author Hardy Ferentschik
+ */
+public interface ElementDescriptor {
+
+ /**
+ * @return <code>true</code> if at least one constraint declaration is
present on the element, <code>false</code> otherwise.
+ */
+ boolean hasConstraints();
+
+ /**
+ * @return Statically defined returned type.
+ *
+ * @todo should it be Type or even completly removed
+ */
+ Class<?> getType();
+
+ /**
+ * Return all constraint descriptors for this element or an
+ * empty Set if none are present.
+ *
+ * @return Set of constraint descriptors for this element
+ */
+ Set<ConstraintDescriptor<?>> getConstraintDescriptors();
+}
Property changes on:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/ElementDescriptor.java
___________________________________________________________________
Name: svn:keywords
+ Id
Copied:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/PropertyDescriptor.java
(from rev 16786,
beanvalidation/trunk/validation-api/src/main/java/javax/validation/PropertyDescriptor.java)
===================================================================
---
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/PropertyDescriptor.java
(rev 0)
+++
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/PropertyDescriptor.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -0,0 +1,23 @@
+package javax.validation.metadata;
+
+/**
+ * Describes a Java Bean property hosting validation constraints.
+ *
+ * Constraints placed on the attribute and the getter of a given property
+ * are all referenced by this object.
+ *
+ * @author Emmanuel Bernard
+ */
+public interface PropertyDescriptor extends ElementDescriptor {
+ /**
+ * Is the property marked by the <code>@Valid</code> annotation.
+ * @return <code>true</code> if the annotation is present,
<code>false</code> otherwise.
+ */
+ boolean isCascaded();
+
+ /**
+ * Name of the property acording to the Java Bean specification.
+ * @return property name.
+ */
+ String getPropertyName();
+}
\ No newline at end of file
Property changes on:
beanvalidation/trunk/validation-api/src/main/java/javax/validation/metadata/PropertyDescriptor.java
___________________________________________________________________
Name: svn:keywords
+ Id
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanDescriptorImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanDescriptorImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanDescriptorImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -1,8 +1,8 @@
package org.hibernate.validation.engine;
import java.util.Set;
-import javax.validation.BeanDescriptor;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.BeanDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
/**
* @author Emmanuel Bernard
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaData.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaData.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaData.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -21,8 +21,8 @@
import java.lang.reflect.Member;
import java.util.List;
import java.util.Set;
-import javax.validation.BeanDescriptor;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.BeanDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
/**
* Interface defining the meta data about the constraints defined in a given bean.
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaDataImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaDataImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/BeanMetaDataImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -30,9 +30,9 @@
import java.util.List;
import java.util.Map;
import java.util.Set;
-import javax.validation.BeanDescriptor;
+import javax.validation.metadata.BeanDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
import javax.validation.GroupSequence;
-import javax.validation.PropertyDescriptor;
import javax.validation.Valid;
import javax.validation.ValidationException;
import javax.validation.groups.Default;
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintDescriptorImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintDescriptorImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintDescriptorImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -30,7 +30,7 @@
import java.util.Set;
import javax.validation.Constraint;
import javax.validation.ConstraintDefinitionException;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintValidator;
import javax.validation.OverridesAttribute;
import javax.validation.ReportAsSingleViolation;
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-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintTree.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -24,7 +24,7 @@
import java.util.List;
import java.util.Map;
import java.util.Set;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintValidator;
import javax.validation.ConstraintValidatorFactory;
import javax.validation.ConstraintViolation;
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintValidatorContextImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintValidatorContextImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintValidatorContextImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -19,7 +19,7 @@
import java.util.ArrayList;
import java.util.List;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintValidatorContext;
/**
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintViolationImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintViolationImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ConstraintViolationImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -17,7 +17,7 @@
*/
package org.hibernate.validation.engine;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintViolation;
/**
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ElementDescriptorImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ElementDescriptorImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ElementDescriptorImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -20,8 +20,8 @@
import java.util.Collections;
import java.util.HashSet;
import java.util.Set;
-import javax.validation.ConstraintDescriptor;
-import javax.validation.ElementDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
+import javax.validation.metadata.ElementDescriptor;
/**
* Describe a validated element (class, field or property).
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ExecutionContext.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ExecutionContext.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ExecutionContext.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -28,7 +28,7 @@
import java.lang.reflect.Member;
import java.lang.reflect.Field;
import java.lang.annotation.ElementType;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintValidatorFactory;
import javax.validation.ConstraintViolation;
import javax.validation.MessageInterpolator;
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MessageInterpolatorContext.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MessageInterpolatorContext.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MessageInterpolatorContext.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -1,6 +1,6 @@
package org.hibernate.validation.engine;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.MessageInterpolator;
/**
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MetaConstraint.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MetaConstraint.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/MetaConstraint.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -20,18 +20,15 @@
import java.lang.annotation.Annotation;
import java.lang.annotation.ElementType;
import java.lang.reflect.Field;
-import java.lang.reflect.GenericArrayType;
import java.lang.reflect.Member;
import java.lang.reflect.Method;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintViolation;
-import com.googlecode.jtype.TypeUtils;
-
import org.hibernate.validation.util.ReflectionHelper;
/**
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/PropertyDescriptorImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/PropertyDescriptorImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/PropertyDescriptorImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -17,7 +17,7 @@
*/
package org.hibernate.validation.engine;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
/**
* Describe a validated element (class, field or property).
Modified:
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ValidatorImpl.java
===================================================================
---
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ValidatorImpl.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/main/java/org/hibernate/validation/engine/ValidatorImpl.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -28,7 +28,7 @@
import java.util.List;
import java.util.Map;
import java.util.Set;
-import javax.validation.BeanDescriptor;
+import javax.validation.metadata.BeanDescriptor;
import javax.validation.ConstraintValidatorFactory;
import javax.validation.ConstraintViolation;
import javax.validation.MessageInterpolator;
Modified:
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/constraints/custom/CustomConstraintValidatorTest.java
===================================================================
---
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/constraints/custom/CustomConstraintValidatorTest.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/constraints/custom/CustomConstraintValidatorTest.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -21,7 +21,7 @@
import javax.validation.Validation;
import javax.validation.Validator;
import javax.validation.ConstraintViolation;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
import org.testng.annotations.Test;
import static org.testng.Assert.*;
Modified:
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/ValidatorImplTest.java
===================================================================
---
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/ValidatorImplTest.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/ValidatorImplTest.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -18,10 +18,10 @@
package org.hibernate.validation.engine;
import java.util.Set;
-import javax.validation.BeanDescriptor;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.BeanDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintViolation;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
import javax.validation.ValidationException;
import javax.validation.Validator;
import javax.validation.groups.Default;
Modified:
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/groups/GroupTest.java
===================================================================
---
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/groups/GroupTest.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/groups/GroupTest.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -18,9 +18,9 @@
package org.hibernate.validation.engine.groups;
import java.util.Set;
-import javax.validation.BeanDescriptor;
+import javax.validation.metadata.BeanDescriptor;
import javax.validation.ConstraintViolation;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
import javax.validation.ValidationException;
import javax.validation.Validator;
import javax.validation.groups.Default;
Modified:
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/inheritance/InheritanceTest.java
===================================================================
---
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/inheritance/InheritanceTest.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/engine/inheritance/InheritanceTest.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -1,4 +1,4 @@
-// $Id:$
+// $Id$
/*
* JBoss, Home of Professional Open Source
* Copyright 2008, Red Hat Middleware LLC, and individual contributors
@@ -18,8 +18,8 @@
package org.hibernate.validation.engine.inheritance;
import java.lang.annotation.Annotation;
-import javax.validation.BeanDescriptor;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.BeanDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
import javax.validation.Validator;
import javax.validation.constraints.NotNull;
Modified:
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/util/TestUtil.java
===================================================================
---
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/util/TestUtil.java 2009-06-15
17:54:38 UTC (rev 16787)
+++
validator/trunk/hibernate-validator/src/test/java/org/hibernate/validation/util/TestUtil.java 2009-06-15
18:03:30 UTC (rev 16788)
@@ -19,10 +19,10 @@
import java.io.InputStream;
import java.util.Set;
-import javax.validation.ConstraintDescriptor;
+import javax.validation.metadata.ConstraintDescriptor;
import javax.validation.ConstraintViolation;
-import javax.validation.ElementDescriptor;
-import javax.validation.PropertyDescriptor;
+import javax.validation.metadata.ElementDescriptor;
+import javax.validation.metadata.PropertyDescriptor;
import javax.validation.Validation;
import javax.validation.Validator;