.getDefaultValue();
if ( defaultPayload.length != 0 ) {
String msg = annotation.annotationType()
.getName() + " contains Constraint annotation, but the payload " +
"paramter default value is not the empty array.";
throw new ConstraintDefinitionException( msg );
}
}
catch ( ClassCastException e ) {
String msg = annotation.annotationType().getName() + " contains Constraint annotation, but the " +
"payload parameter is of wrong type.";
throw new ConstraintDefinitionException( msg );
}
catch ( NoSuchMethodException nsme ) {
String msg = annotation.annotationType().getName() + " contains Constraint annotation, but does " +
"not contain a payload parameter.";
throw new ConstraintDefinitionException( msg );
}
}