use of org.knime.core.node.defaultnodesettings.DialogComponent in project knime-core by knime.
the class ColumnAggregatorNodeDialog method saveSettingsTo.
/**
* {@inheritDoc}
*/
@Override
protected void saveSettingsTo(final NodeSettingsWO settings) throws InvalidSettingsException {
for (final DialogComponent component : m_components) {
component.saveSettingsTo(settings);
}
// since the table does not loose focus when OK or Apply is pressed.
try {
m_aggrMethodsPanel.stopCellEditing();
} catch (IllegalArgumentException e) {
System.out.println(e.getMessage());
}
m_aggrMethodsPanel.saveSettingsTo(settings.addNodeSettings(ColumnAggregatorNodeModel.CFG_AGGREGATION_METHODS));
m_version.saveSettingsTo(settings);
}
use of org.knime.core.node.defaultnodesettings.DialogComponent in project knime-core by knime.
the class PredictorNodeDialog method saveSettingsTo.
/**
* {@inheritDoc}
*/
@Override
protected void saveSettingsTo(final NodeSettingsWO settings) throws InvalidSettingsException {
for (DialogComponent comp : m_dialogComponents) {
comp.saveSettingsTo(settings);
}
m_overridePredModel.setBooleanValue(m_overridePred.isSelected());
m_overridePredModel.saveSettingsTo(settings);
m_predictionColModel.setEnabled(m_predColName.isEnabled());
m_predictionColModel.setStringValue(m_predColName.getText());
if (m_predColName.isEnabled() && m_predColName.getText().isEmpty()) {
throw new InvalidSettingsException("Please specify a prediction column name.");
}
m_predictionColModel.saveSettingsTo(settings);
m_addProbsModel.setBooleanValue(m_addProbs.isSelected());
m_addProbsModel.saveSettingsTo(settings);
m_suffixModel.setEnabled(m_suffix.isEnabled());
m_suffixModel.setStringValue(m_suffix.getText());
m_suffixModel.saveSettingsTo(settings);
}
Aggregations