org.knime.base.node.preproc.pivot
Class Pivot2NodeDialog

java.lang.Object
  extended by org.knime.core.node.NodeDialogPane
      extended by org.knime.base.node.preproc.groupby.GroupByNodeDialog
          extended by org.knime.base.node.preproc.pivot.Pivot2NodeDialog

public class Pivot2NodeDialog
extends GroupByNodeDialog

The node dialog of the pivot node.

Author:
Thomas Gabriel, KNIME.com AG, Switzerland

Field Summary
 
Fields inherited from class org.knime.base.node.preproc.groupby.GroupByNodeDialog
DEFAULT_HEIGHT, DEFAULT_WIDTH
 
Constructor Summary
Pivot2NodeDialog()
          Constructor for class Pivot2NodeDialog.
 
Method Summary
(package private) static SettingsModelBoolean createSettingsIgnoreDomain()
           
(package private) static SettingsModelBoolean createSettingsMissingValues()
           
(package private) static SettingsModelBoolean createSettingsTotal()
           
protected  void excludeColumns(List<String> columns)
          Synchronizes the available aggregation column list and the selected columns.
protected  void loadSettingsFrom(NodeSettingsRO settings, PortObjectSpec[] specs)
          Invoked before the dialog window is opened.
protected  void saveSettingsTo(NodeSettingsWO settings)
          Invoked when the settings need to be applied.
 
Methods inherited from class org.knime.base.node.preproc.groupby.GroupByNodeDialog
addPanel, columnsChanged, inMemoryChanged
 
Methods inherited from class org.knime.core.node.NodeDialogPane
addFlowVariablesTab, addJobMgrTab, addTab, addTabAt, closeOnESC, createFlowVariableModel, createFlowVariableModel, createFlowVariableModel, finishEditingAndSaveSettingsTo, getAvailableFlowVariables, getCredentialsNames, getCredentialsProvider, getPanel, getTab, getTabIndex, internalLoadSettingsFrom, isWriteProtected, loadSettingsFrom, loadSettingsFrom, onCancel, onClose, onOpen, removeTab, renameTab, saveSettingsTo, setEnabled, setSelected
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Pivot2NodeDialog

public Pivot2NodeDialog()
Constructor for class Pivot2NodeDialog.

Method Detail

createSettingsMissingValues

static final SettingsModelBoolean createSettingsMissingValues()
Returns:
settings model boolean for ignoring missing values

createSettingsTotal

static final SettingsModelBoolean createSettingsTotal()
Returns:
settings model boolean for total aggregation

createSettingsIgnoreDomain

static final SettingsModelBoolean createSettingsIgnoreDomain()
Returns:
settings model boolean for ignoring domain

excludeColumns

protected void excludeColumns(List<String> columns)
Synchronizes the available aggregation column list and the selected columns.

Overrides:
excludeColumns in class GroupByNodeDialog
Parameters:
columns - the column that are changed and need to be excluded from the aggregation list

loadSettingsFrom

protected void loadSettingsFrom(NodeSettingsRO settings,
                                PortObjectSpec[] specs)
                         throws NotConfigurableException
Invoked before the dialog window is opened. The settings object passed, contains the current settings of the corresponding node model. The model and the dialog must agree on a mutual contract on how settings are stored in the spec. I.e. they must able to read each other's settings.

The implementation must be able to handle invalid or incomplete settings as the model may not have any reasonable values yet (for example when the dialog is opened for the first time). When an empty/invalid settings object is passed the dialog should set default values in its components.

Overrides:
loadSettingsFrom in class GroupByNodeDialog
Parameters:
settings - The settings to load into the dialog. Could be an empty object or contain invalid settings. But will never be null.
specs - The input data table specs. Items of the array could be null if no spec is available from the corresponding input port (i.e. not connected or upstream node does not produce an output spec). If a port is of type BufferedDataTable.TYPE and no spec is available the framework will replace null by an empty DataTableSpec (no columns) unless the port is marked as optional.
Throws:
NotConfigurableException - if the dialog cannot be opened because of real invalid settings or if any preconditions are not fulfilled, e.g. no predecessor node, no nominal column in input table, etc.
See Also:
NodeModel.loadSettingsFrom(NodeSettingsRO)

saveSettingsTo

protected void saveSettingsTo(NodeSettingsWO settings)
                       throws InvalidSettingsException
Invoked when the settings need to be applied. The implementation should write the current user settings from its components into the passed object. It should not check consistency or completeness of the settings - this is part of the model's load method. The only situation this method would throw an exception is when a component contains an invalid value that can't be stored in the settings object.
The settings must be written in a way the model is able to load in, i.e. with the model's keys.

Overrides:
saveSettingsTo in class GroupByNodeDialog
Parameters:
settings - The settings object to write into.
Throws:
InvalidSettingsException - If the settings are not applicable to the model.
See Also:
NodeModel.loadSettingsFrom(NodeSettingsRO)


Copyright, 2003 - 2012. All rights reserved.
University of Konstanz, Germany.
Chair for Bioinformatics and Information Mining, Prof. Dr. Michael R. Berthold.
You may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display, or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the copyright owner or as specified in the license file distributed with this product.