use of org.knime.core.node.util.ColumnFilterPanel in project knime-core by knime.
the class CategoryToNumberNodeDialogPane method createCategoryToNumberSettingsTab.
@SuppressWarnings("unchecked")
private JPanel createCategoryToNumberSettingsTab() {
JPanel p = new JPanel(new GridBagLayout());
GridBagConstraints c = new GridBagConstraints();
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.NORTHWEST;
c.insets = new Insets(2, 2, 2, 2);
c.gridx = 0;
c.gridy = 0;
c.gridwidth = 1;
c.weightx = 1;
c.weighty = 0;
Insets leftInsets = new Insets(3, 8, 3, 8);
Insets middleInsets = new Insets(3, 0, 3, 0);
c.gridwidth = 3;
m_includedColumns = new ColumnFilterPanel(true, StringValue.class);
p.add(m_includedColumns, c);
c.weighty = 0;
c.weightx = 0;
c.gridy++;
c.gridwidth = 2;
c.gridx = 0;
c.insets = leftInsets;
m_appendColums = new JCheckBox("Append columns");
m_appendColums.addActionListener(new ActionListener() {
@Override
public void actionPerformed(final ActionEvent e) {
m_columnSuffix.setEnabled(m_appendColums.isSelected());
}
});
p.add(m_appendColums, c);
c.gridy++;
c.gridwidth = 1;
c.gridx = 0;
c.insets = leftInsets;
p.add(new JLabel("Column suffix:"), c);
c.gridx = 1;
c.insets = middleInsets;
m_columnSuffix = new JTextField();
p.add(m_columnSuffix, c);
c.gridy++;
c.gridwidth = 1;
c.gridx = 0;
c.insets = leftInsets;
p.add(new JLabel("Start value:"), c);
c.gridx = 1;
c.insets = middleInsets;
m_startIndex = new JSpinner(new SpinnerNumberModel(0, Integer.MIN_VALUE, Integer.MAX_VALUE, 1));
p.add(m_startIndex, c);
c.gridy++;
c.gridwidth = 1;
c.gridx = 0;
c.insets = leftInsets;
p.add(new JLabel("Increment:"), c);
c.gridx = 1;
c.insets = middleInsets;
m_increment = new JSpinner(new SpinnerNumberModel(1, 1, Integer.MAX_VALUE, 1));
p.add(m_increment, c);
c.gridy++;
c.gridwidth = 1;
c.gridx = 0;
c.insets = leftInsets;
p.add(new JLabel("Max. categories:"), c);
c.gridx = 1;
c.insets = middleInsets;
m_maxCategories = new JSpinner(new SpinnerNumberModel(1000, 1, Integer.MAX_VALUE, 100));
p.add(m_maxCategories, c);
c.gridy++;
c.gridwidth = 1;
c.gridx = 0;
c.insets = leftInsets;
p.add(new JLabel("Default value:"), c);
c.gridx = 1;
c.insets = middleInsets;
m_defaultValue = new JTextField();
m_defaultValue.setHorizontalAlignment(JTextField.RIGHT);
p.add(m_defaultValue, c);
c.gridy++;
c.gridwidth = 1;
c.gridx = 0;
c.insets = leftInsets;
p.add(new JLabel("Map missing to:"), c);
c.gridx = 1;
c.insets = middleInsets;
m_mapMissingTo = new JTextField();
m_mapMissingTo.setHorizontalAlignment(JTextField.RIGHT);
p.add(m_mapMissingTo, c);
c.gridy++;
c.weighty = 1;
p.add(new JPanel(), c);
return p;
}
use of org.knime.core.node.util.ColumnFilterPanel in project knime-core by knime.
the class Joiner2NodeDialog method createColumnSelectionTab.
private JComponent createColumnSelectionTab(final String topTitle, final String bottomTitle) {
JPanel p = new JPanel(new GridBagLayout());
GridBagConstraints c = new GridBagConstraints();
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.NORTHWEST;
c.insets = new Insets(2, 2, 2, 2);
c.gridx = 0;
c.gridy = 0;
c.weightx = 1;
c.gridwidth = 1;
m_leftFilterPanel = new ColumnFilterPanel(true);
m_leftFilterPanel.setBorder(BorderFactory.createTitledBorder(topTitle));
p.add(m_leftFilterPanel, c);
c.gridy++;
m_rightFilterPanel = new ColumnFilterPanel(true);
m_rightFilterPanel.setBorder(BorderFactory.createTitledBorder(bottomTitle));
p.add(m_rightFilterPanel, c);
c.gridy++;
p.add(createDuplicateColumnHandlingUIConstrols(), c);
return new JScrollPane(p);
}
use of org.knime.core.node.util.ColumnFilterPanel in project knime-core by knime.
the class DBJoinerNodeDialog method createColumnSelectionTab.
private JComponent createColumnSelectionTab() {
JPanel p = new JPanel(new GridBagLayout());
GridBagConstraints c = new GridBagConstraints();
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.NORTHWEST;
c.insets = new Insets(2, 2, 2, 2);
c.gridx = 0;
c.gridy = 0;
c.weightx = 1;
c.gridwidth = 1;
m_leftFilterPanel = new ColumnFilterPanel(true);
m_leftFilterPanel.setBorder(BorderFactory.createTitledBorder("Top Input ('left' table)"));
p.add(m_leftFilterPanel, c);
c.gridy++;
m_rightFilterPanel = new ColumnFilterPanel(true);
m_rightFilterPanel.setBorder(BorderFactory.createTitledBorder("Bottom Input ('right' table)"));
p.add(m_rightFilterPanel, c);
c.gridy++;
p.add(createDuplicateColumnHandlingUIConstrols(), c);
return new JScrollPane(p);
}
use of org.knime.core.node.util.ColumnFilterPanel in project knime-core by knime.
the class AutoBinnerLearnNodeDialogPane method createAutoBinnerSettingsTab.
/**
* @return
*/
@SuppressWarnings("unchecked")
private JPanel createAutoBinnerSettingsTab() {
JPanel p = new JPanel(new GridBagLayout());
GridBagConstraints c = new GridBagConstraints();
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.NORTHWEST;
c.insets = new Insets(2, 2, 2, 2);
c.gridx = 0;
c.gridy = 0;
c.gridwidth = 1;
c.weightx = 1;
c.weighty = 1;
m_targetCol = new ColumnFilterPanel(true, DoubleValue.class);
p.add(m_targetCol, c);
c.gridy++;
p.add(createMethodUIControls(), c);
c.gridy++;
p.add(createBinNamingUIControls(), c);
m_integerBounds = new JCheckBox("Force integer bounds");
c.gridy++;
p.add(m_integerBounds, c);
c.gridy++;
m_replaceColumn = new JCheckBox("Replace target column(s)");
p.add(m_replaceColumn, c);
return p;
}
use of org.knime.core.node.util.ColumnFilterPanel in project knime-core by knime.
the class AutoBinnerLearnNodeDialogPane method createAutoBinnerSettingsTab.
/**
* @return
*/
@SuppressWarnings("unchecked")
private JPanel createAutoBinnerSettingsTab() {
JPanel p = new JPanel(new GridBagLayout());
GridBagConstraints c = new GridBagConstraints();
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.NORTHWEST;
c.insets = new Insets(2, 2, 2, 2);
c.gridx = 0;
c.gridy = 0;
c.gridwidth = 1;
c.weightx = 1;
c.weighty = 1;
m_targetCol = new ColumnFilterPanel(true, DoubleValue.class);
p.add(m_targetCol, c);
c.gridy++;
p.add(createMethodUIControls(), c);
c.gridy++;
p.add(createBinNamingUIControls(), c);
c.gridy++;
m_replaceColumn = new JCheckBox("Replace target column(s)");
p.add(m_replaceColumn, c);
return p;
}
Aggregations