}
}
throw new IllegalArgumentException(sb.toString());
}
if (fieldConfig.isThrowIfNull() && !dataPersister.isPrimitive()) {
throw new SQLException("Field " + field.getName() + " must be a primitive if set with throwIfNull");
}
if (this.isId && !dataPersister.isAppropriateId()) {
throw new SQLException("Field '" + field.getName() + "' is of data type " + dataPersister
+ " which cannot be the ID field");
}
this.dataTypeConfigObj = dataPersister.makeConfigObject(this);
String defaultStr = fieldConfig.getDefaultValue();
if (defaultStr == null || defaultStr.equals("")) {
this.defaultValue = null;
} else if (this.isGeneratedId) {
throw new SQLException("Field '" + field.getName() + "' cannot be a generatedId and have a default value '"
+ defaultStr + "'");
} else {
this.defaultValue = this.fieldConverter.parseDefaultString(this, defaultStr);
}
}