StreamableKNIME Java Snippet Nodes version 3.5.0.v201711081409 by KNIME AG, Zurich, Switzerland
This node allows you to execute arbitrary java code to create a new columns or to replace an existing ones. Enter the java code in the text area.
An output columns is defined by creating a java field bound to this column. The value assigned to this field will be written to the output.
Note, that this node allows to add or modify flow variables in the same manner.
It is also possible to use external java libraries (that is, libraries that are not part of java boot classpath). In order to include such external jar or zip files, add their location in the "Additional Libraries" tab using the control buttons.
You can define reusable templates with the "Create templates..." button. Templates are stored in the users workspace by default and can be accessed via the "Templates" tab.
You can hit ctrl+space to get an auto completion box with all available classes, methods and fields. When you select a class and hit enter a import statement will be generated if missing.
Note, that the snippet allows to define custom global variables and custom imports.
Exceptions in the snippet are caught by the framework and will
result in missing values for all output columns for the row being processed unless there are
flow variables defined by the snippet (in which case the execution will always fail).
You can force the node to fail execution by throwing an exception of class
To use this node in KNIME, install KNIME Java Snippet Nodes from the following update site: