uniqueness validation is now also supported by the validation rules editor

This commit is contained in:
2016-08-05 23:45:23 +02:00
parent b6731f7641
commit 6af20575e8
6 changed files with 57 additions and 28 deletions

View File

@@ -52,7 +52,7 @@ public class ValidationConfiguration {
headerConfiguration.setNames(headerNames);
}
public Boolean getUniquenessRuleFor(String column) {
public Boolean getUniqueRuleFor(String column) {
return (Boolean)getValue(column, "unique");
}
@@ -114,6 +114,11 @@ public class ValidationConfiguration {
setValue(column, value, "not empty");
}
public void setUniqueRuleFor(String column, Boolean value) {
setValue(column, value, "unique");
}
public void setMinLengthRuleFor(String column, Integer value) {
setValue(column, value == null ? null : value.doubleValue(), "minlength");
}