Add the property name to the path.
Review at http://gwt-code-reviews.appspot.com/1233802
Review by: rchandia@google.com
git-svn-id: https://google-web-toolkit.googlecode.com/svn/trunk@9465 8db76d5a-ed1c-0410-87a9-c151d255dfc7
diff --git a/user/src/com/google/gwt/validation/rebind/GwtSpecificValidatorCreator.java b/user/src/com/google/gwt/validation/rebind/GwtSpecificValidatorCreator.java
index 4d5e720..f930100 100644
--- a/user/src/com/google/gwt/validation/rebind/GwtSpecificValidatorCreator.java
+++ b/user/src/com/google/gwt/validation/rebind/GwtSpecificValidatorCreator.java
@@ -730,7 +730,7 @@
private void writeValidateConstraint(SourceWriter sw, PropertyDescriptor p,
Class<?> elementClass, ConstraintDescriptor<?> constraint,
String constraintDescriptorVar) {
- Class<? extends ConstraintValidator<? extends Annotation, ?>> validatorClass =
+ Class<? extends ConstraintValidator<? extends Annotation, ?>> validatorClass =
getValidatorForType(constraint, elementClass);
if (validatorClass == null) {
// TODO(nchalko) What does the spec say to do here.
@@ -940,6 +940,12 @@
sw.println("Class<?>... groups) {");
sw.outdent();
+ // TODO(nchalko) handle the other path types.
+ // context = context.append("myProperty");
+ sw.print("context = context.append(\"");
+ sw.print(p.getPropertyName());
+ sw.println("\");");
+
// TODO(nchalko) move this out of here to the Validate method
if (p.isCascaded() && !isIterable(elementClass)) {