Audit config, XSD and write-persistence tests

- Audit paths can now use mixed case (after alf_prop_string_value enhancements)
 - Pluggable data conversion when pushing values into persistence
 - Relaxed XSD to allow mixed-case key values
 - Regex checking of paths and names when building strings


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@15976 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2009-08-27 16:16:05 +00:00
parent 19d232f649
commit f0cd5ef0d8
19 changed files with 427 additions and 139 deletions

View File

@@ -326,7 +326,8 @@ public class PropertyValueEntity
persistedTypeEnum = persistedTypesByClass.get(valueClazz);
if (persistedTypeEnum == null)
{
persistedTypeEnum = PersistedType.SERIALIZABLE;
// Give the converter a chance to change the type it must be persisted as
persistedTypeEnum = converter.getPersistentType(value);
}
persistedType = persistedTypeEnum.getOrdinalNumber();
// Get the class to persist as
@@ -345,7 +346,11 @@ public class PropertyValueEntity
serializableValue = value;
break;
default:
throw new IllegalStateException("Should not be able to get through switch");
throw new IllegalStateException(
"PropertyTypeConverter.convertToPersistentType returned illegal type: " +
" Converter: " + converter + "\n" +
" Type Returned: " + persistedTypeEnum + "\n" +
" From Value: " + value);
}
}
}