use of org.knime.core.node.defaultnodesettings.SettingsModelString in project knime-core by knime.
the class TableToVariableNodeDialog method getReplaceString.
/**
* @param policyModel The policy model.
* @return the SM for the new String value.
*/
static final SettingsModelString getReplaceString(final SettingsModelString policyModel) {
SettingsModelString model = new SettingsModelString("CFG_String", "missing");
ChangeListener listener = new PolicyChangeListener(policyModel, model);
policyModel.addChangeListener(listener);
listener.stateChanged(null);
return model;
}
use of org.knime.core.node.defaultnodesettings.SettingsModelString in project knime-core by knime.
the class DBConnectionWriterNodeModel method validateSettings.
/**
* {@inheritDoc}
*/
@Override
protected void validateSettings(final NodeSettingsRO settings) throws InvalidSettingsException {
SettingsModelString tableName = m_tableName.createCloneWithValidatedValue(settings);
String tableString = tableName.getStringValue();
if (tableString == null || tableString.trim().isEmpty()) {
throw new InvalidSettingsException("Configure node and enter a valid table name.");
}
}
use of org.knime.core.node.defaultnodesettings.SettingsModelString in project knime-core by knime.
the class DBQueryNodeModel method validateSettings.
/**
* {@inheritDoc}
*/
@Override
protected void validateSettings(final NodeSettingsRO settings) throws InvalidSettingsException {
super.validateSettings(settings);
SettingsModelString query = m_query.createCloneWithValidatedValue(settings);
String queryString = query.getStringValue();
if (queryString != null && !queryString.contains(TABLE_PLACE_HOLDER)) {
throw new InvalidSettingsException("Database view place holder (" + TABLE_PLACE_HOLDER + ") must not be replaced.");
}
}
use of org.knime.core.node.defaultnodesettings.SettingsModelString in project knime-core by knime.
the class CorrelationOperator method getDialogComponent.
private DialogComponentButtonGroup getDialogComponent() {
if (m_correlationComponent == null) {
final SettingsModelString correlationModel = m_settings.getCorrelationMethodModel();
m_correlationComponent = new DialogComponentButtonGroup(correlationModel, "Correlation method", false, CorrelationMethods.values());
}
return m_correlationComponent;
}
use of org.knime.core.node.defaultnodesettings.SettingsModelString in project knime-core by knime.
the class PivotNodeDialogPane method createSettingsAggregation.
/**
* @return a settings model string as pivot column
*/
static final SettingsModelString createSettingsAggregation() {
SettingsModelString model = new SettingsModelString("aggregation_column", null);
model.setEnabled(false);
return model;
}
Aggregations