} else {
((CheckBox) lEditorComponent).setSelected(false);
}
break;
case DEV:
lEditorComponent = new ComboBox();
List<String> authorizedValues = getAuthorizedValues(param);
boolean hasFoundExpectedDevices = false;
final String[] devicesClass = param.getDevicesClass();
if (devicesClass != null && devicesClass.length != 0) {
try {
List<String> devicesForClass = getDevicesForClasses(devicesClass);
for (String s : devicesForClass) {
if (authorizedValues.isEmpty() || authorizedValues.contains(s)) {
hasFoundExpectedDevices = true;
((ComboBox) lEditorComponent).addItem(s);
if (s.equalsIgnoreCase(entry.getValue())) {
((ComboBox) lEditorComponent).setSelectedItem(s);
}
}
}
} catch (DevFailed e) {
LOGGER.log(Level.SEVERE, e.getMessage());
}
if (!hasFoundExpectedDevices) {
String err = "No expected device matches given constraints: "
+ ArrayUtils.toString(devicesClass) + " " + ArrayUtils.toString(param.getConstraints());
String location = getErrorLocation(entryContainer, null, entry);
JTextArea labelError = getTextAreaError(err, location, lEditorComponent, labelName, tabTitle);
panelError.add(labelError);
panelError.revalidate();
errorsMap.put(lEditorComponent, labelError);
}
}
break;
case DEV_ATTR:
/* lEditorComponent = new ComboBox();
List<String> authorizedValuesAttr = getAuthorizedValues(param);
boolean hasFoundExpectedDevices2 = false;
if (param.getDevicesClass() != null && param.getDevicesClass().length != 0) {
for (String myClass : param.getDevicesClass()) {
try {
String[] exportedDevices = TangoDeviceHelper.getDatabase().get_device_exported_for_class(
myClass);
for (String s : exportedDevices) {
if (authorizedValuesAttr.isEmpty() || authorizedValuesAttr.contains(s)) {
hasFoundExpectedDevices2 = true;
((ComboBox) lEditorComponent).addItem(s);
if (s.equalsIgnoreCase(entry.getValue())) {
((ComboBox) lEditorComponent).setSelectedItem(s);
}
}
}
} catch (DevFailed e) {
LOGGER.log(Level.SEVERE, e.getMessage());
}
}
if (!hasFoundExpectedDevices2) {
throw new FSParsingException("No expected device matches given constraints: "
+ ArrayUtils.toString(param.getDevicesClass()) + " "
+ ArrayUtils.toString(param.getConstraints()), lEditorComponent, labelName);
}
} else {
if (param.getAttributeList() != null && param.getAttributeList().length != 0) {
for (String s : param.getAttributeList()) {
if (authorizedValuesAttr.isEmpty() || authorizedValuesAttr.contains(s)) {
((ComboBox) lEditorComponent).addItem(s);
if (s.equalsIgnoreCase(entry.getValue())) {
((ComboBox) lEditorComponent).setSelectedItem(s);
}
}
}
}
}*/
lEditorComponent = new TextField();
((TextField) lEditorComponent).setText(entry.getValue());
((TextField) lEditorComponent).setColumns(50);
break;
case ENUM:
lEditorComponent = new ComboBox();
if (param.getValues() == null || param.getValues().length == 0) {
throw new FSParsingException("Plugin parameter " + param.getName()
+ " must have a values property.", lEditorComponent, labelName);
}
for (String s : param.getValues()) {