private Type toType(String xmlType) { if (xmlType != null) { return Type.valueOf(xmlType.toUpperCase()); } return null; }
configParamProperty.add(""); configParamProperty.add(TYPE); configParamProperty.add(parameter.getType().toString()); configParamContent.add(Utils.getRow(columnWidths, configParamProperty)); if (parameter.getLabel() != null) {
configParamProperty.add(""); configParamProperty.add(TYPE); configParamProperty.add(parameter.getType().toString()); configParamContent.add(Utils.getRow(columnWidths, configParamProperty)); if (parameter.getLabel() != null) {
private void checkType(Object configValue, ConfigDescriptionParameter configParameter) { Type type = configParameter.getType(); if (configParameter.isMultiple()) { if (configValue instanceof List) { List lConfigValues = (List) configValue; for (Object value : lConfigValues) { if (!checkType(type, value)) { throw new IllegalArgumentException("Unexpected value for configuration property \"" + configParameter.getName() + "\". Expected type: " + type); } } } throw new IllegalArgumentException( "Unexpected value for configuration property \"" + configParameter.getName() + "\". Expected is Array with type for elements : " + type.toString() + "!"); } else { if (!checkType(type, configValue)) { throw new IllegalArgumentException("Unexpected value for configuration property \"" + configParameter.getName() + "\". Expected is " + type.toString() + "!"); } } }