String name = getStringValue(element, "name");
ConfigToken<?> configToken = TableConfig.findByPropertyName(name);
String value = getStringValue(element, "value");
if (configToken == null) {
throw new ConfigurationProcessingException("'" + name
+ "' is not a valid property. Please read the documentation.");
} else {
if (configs.get(tableId).containsKey(ConfType.PROPERTY)) {
((Map<ConfigToken<?>, Object>) configs.get(tableId).get(ConfType.PROPERTY)).put(configToken,
value);
} else {
Map<ConfigToken<?>, Object> stagingConf = new HashMap<ConfigToken<?>, Object>();
stagingConf.put(configToken, value);
configs.get(tableId).put(ConfType.PROPERTY, stagingConf);
}
}
} else {
throw new ConfigurationProcessingException(
"The attribute 'dt:name' is required when overloading a configuration property.");
}
}