Hi!
I'm having a really hard time implementing a node dialog of selecting the column to process.
I can select the column in the node but when clicking apply or ok it returns the following eror message:
Invalid settings: Config for key "columnName" not found.
My Code is listed below, am I missing something?
THanks and cheers
chris
NodeDialog:
public class MydummyNodeDialog extends DefaultNodeSettingsPane {
/**
* New pane for configuring Mydummy node dialog. This is just a suggestion
* to demonstrate possible default dialog components.
*/
@SuppressWarnings("unchecked")
protected MydummyNodeDialog() {
super();
addDialogComponent(new DialogComponentColumnNameSelection(
new SettingsModelString(MydummyNodeModel.CFGKEY_COLUMN_NAME,
""), "Select a column:", 0, org.knime.core.data.StringValue.class));
}
}
NodeModel excerpt:
public static final String CFGKEY_COLUMN_NAME = "columnName";
private final SettingsModelColumnName m_column = new SettingsModelColumnName(
MydummyNodeModel.CFGKEY_COLUMN_NAME, "");
protected DataTableSpec[] configure(final DataTableSpec[] inSpecs)
throws InvalidSettingsException {
return new DataTableSpec[] { null };
}
protected void saveSettingsTo(final NodeSettingsWO settings) {
m_column.saveSettingsTo(settings);
}
protected void loadValidatedSettingsFrom(final NodeSettingsRO settings)
throws InvalidSettingsException {
m_column.loadSettingsFrom(settings);
}
protected void validateSettings(final NodeSettingsRO settings)
throws InvalidSettingsException {
m_column.validateSettings(settings);
}