if (providerName == null) {
problems.addError(JcrI18n.indexMustHaveProviderName, defn.getName(), repository.name());
continue;
}
if (defn.hasSingleColumn()) {
IndexColumnDefinition columnDefn = defn.getColumnDefinition(0);
Name propName = context.getValueFactories().getNameFactory().create(columnDefn.getPropertyName());
switch (defn.getKind()) {
case UNIQUE_VALUE:
if (NON_UNIQUE_PROPERTY_NAMES.contains(propName)) {
problems.addError(JcrI18n.unableToCreateUniqueIndexForColumn, defn.getName(),
columnDefn.getPropertyName());
}
break;
case ENUMERATED_VALUE:
if (NON_ENUMERATED_PROPERTY_NAMES.contains(propName)) {
problems.addError(JcrI18n.unableToCreateEnumeratedIndexForColumn, defn.getName(),
columnDefn.getPropertyName());
}
break;
case VALUE:
case NODE_TYPE:
case TEXT: