Package org.knime.core.webui.node.view
Class NodeViewManager
java.lang.Object
org.knime.core.webui.node.view.NodeViewManager
Manages (web-ui) node view instances and provides associated functionality.
- Since:
- 4.5
- Author:
- Martin Horn, KNIME GmbH, Konstanz, Germany, Marc Bux, KNIME GmbH, Berlin, Germany
-
Method Summary
Modifier and TypeMethodDescriptionbooleancanBeUsedInReport(org.knime.core.node.workflow.NativeNodeContainer nnc) getDefaultPageFormat(org.knime.core.node.workflow.NodeContainer nc) Optional<org.knime.core.data.DataTableSpec>getInputDataTableSpecIfTableView(org.knime.core.node.workflow.NodeContainer nc) static NodeViewManagerReturns the singleton instance for this class.static booleanhasNodeView(org.knime.core.node.workflow.NodeContainer nc) voidupdateNodeViewSettings(org.knime.core.node.workflow.NativeNodeContainer nnc) Updates the view settings of a already created node view (i.e.voidvalidateSettings(org.knime.core.node.workflow.NodeContainer nc, org.knime.core.node.NodeSettings viewSettings)
-
Method Details
-
getInstance
Returns the singleton instance for this class.- Returns:
- the singleton instance
-
hasNodeView
public static boolean hasNodeView(org.knime.core.node.workflow.NodeContainer nc) - Parameters:
nc- the node container to check- Returns:
- whether the node container provides a
NodeView
-
updateNodeViewSettings
public void updateNodeViewSettings(org.knime.core.node.workflow.NativeNodeContainer nnc) throws org.knime.core.node.InvalidSettingsException Updates the view settings of a already created node view (i.e. a node view that has already been requested viagetNodeView(NodeContainer)at least once). Updating the view settings means to get the current node settings from the node and provide them to the view (viaNodeView.loadValidatedSettingsFrom(org.knime.core.node.NodeSettingsRO). NOTE: The settings (values) being passed to the node view are already combined with upstream flow variables (in case settings are overwritten by flow variables).- Parameters:
nnc- the node container to update the node view for- Throws:
org.knime.core.node.InvalidSettingsException- if settings couldn't be updatedIllegalArgumentException- if the passed node container does not provide a node view
-
getDataServiceManager
- Returns:
- the
DataServiceManagerinstance
-
getPageResourceManager
- Returns:
- the
PageResourceManagerinstance
-
getTableViewManager
- Returns:
- the
TableViewManagerinstance
-
canBeUsedInReport
public boolean canBeUsedInReport(org.knime.core.node.workflow.NativeNodeContainer nnc) - Parameters:
nnc-- Returns:
- see
NodeView.canBeUsedInReport()
-
getInputDataTableSpecIfTableView
public Optional<org.knime.core.data.DataTableSpec> getInputDataTableSpecIfTableView(org.knime.core.node.workflow.NodeContainer nc) - Parameters:
nc-- Returns:
- the
DataTableSpecif the node view is also aTableViewotherwise an empty optional
-
validateSettings
public void validateSettings(org.knime.core.node.workflow.NodeContainer nc, org.knime.core.node.NodeSettings viewSettings) throws org.knime.core.node.InvalidSettingsException - Parameters:
nc-viewSettings-- Throws:
org.knime.core.node.InvalidSettingsException
-
getDefaultPageFormat
- Parameters:
nc-- Returns:
- see
NodeView.getDefaultPageFormat()
-