if (!(iValue instanceof String) && !iFieldType.isAssignableFrom(iValue.getClass()))
throw new IllegalArgumentException("Property '" + iFieldName + "' of type '" + iFieldType
+ "' can't accept value of type: " + iValue.getClass());
} else if (Date.class.isAssignableFrom(iFieldType)) {
if (iValue instanceof String && _database != null) {
final OStorageConfiguration config = _database.getStorage().getConfiguration();
DateFormat formatter = config.getDateFormatInstance();
if (((String) iValue).length() > config.dateFormat.length()) {
// ASSUMES YOU'RE USING THE DATE-TIME FORMATTE
formatter = config.getDateTimeFormatInstance();
}
try {
Date newValue = formatter.parse((String) iValue);
// _fieldValues.put(iFieldName, newValue);