The NodeDescription is the information displayed in the NodeDescription window of your workbench. You can edit the information in the XML file, which is named exactly like your
NodeFactory. In our case it is the
NumericBinnerNodeFactory.xml. The NodeDescription explains the functionality of the node, the configuration options, the node's view and the meaning of the in- and outports. When you look at the
NumericBinnerNodeFactory.xml file you will notice that there are already some fields but most of them filled with placeholders. We will go through each of the fields and add the appropriate information.
- The full description should explain the functionality of your node and help a user to use it. For example: "divides the domain of a selected numeric column into the selected number of equidistant bins and puts the input data into these bins accourdingly. The binning information (which row is in which bin) is provided in an extra column at the output."
- for each control element in your dialog describe the meaning of it here. The option name is the label of it used in the dialog. We add:
<option name="Number of bins">Define the number of bins</option> <option name="Column to bin">Select the numeric column which should be binned</option>
- the input ports with their index (which has to match the order in the NodeModel's constructor), a name displayed in the tooltip and a description, which is displayed in the NodeDescription,
- the output ports with the index (which, again, has to match the order in the NodeModel's constructor), a name displayed in the tooltip and in the context menu and a description, which is displayed in the NodeDescription,
<ports> <inPort index="0" name="Data to bin">Data to bin</inPort> <outPort index="0" name="Binned data">The input data with an additional column containing the referring bin number for each row.</outPort> <outPort index="1" name="Bin intervals">Bounds of the intervals</outPort> </ports>
- explains what is displayed in the view with an index of the view (since a node may have several views), a name displayed in the context menu and a description for the NodeDescription. We add:
<views> <view index="0" name="Histogram">Displays the relative size of each bin in a histogram</view> </views>