43
}
}
/**
* Method called by the dialog to save properties in Model
*/
public void saveProperties()
throws NodeDialog.DialogException {
super.saveProperties();
XTProps props = getNodeModel().getXTProps();
// clear old selected values
props.removeProperty(new String []
{ThirdCopyEngineNode.COLUMNS_ATTRIBUTE_TAG});
// Save the names of the selected columns
Object [] selectedValues =
listBox.getSelectedValues();
for (int i=0; i < selectedValues.length; i++) {
props.set(new String []
{ThirdCopyEngineNode.COLUMNS_ATTRIBUTE_TAG,
(String) selectedValues[i]}, "");
}
// Clear out the list to release memory
listModel.clear();
}
/**
* Create the first options page. We hardcode label text
* in this example. It's preferable to put the text in
* an external ResourceBundle for potential
* internationalization.
*/
public JPanel createOptionsPanel() {
JPanel optionsPanel = new JPanel(new GridBagLayout());
optionsPanel.setBorder(
BorderFactory.createEmptyBorder(5,5,5,5));
Comentários a estes Manuais