Repository Category and Icon

Hi,

I am new to KNIME and have been working on building a custom node.  It was going well until I got to the part where I added the node to the repository.

When I test the node in KNIME, the node appear under the category "UNCATEGORIZED".

This node that I have created is a reader and I wanted to place it under the IO Category within the Reader subcategory.

Please advise.  Thanks,

Ky

Hi Ky,

Probably you still have the category definition within your plugin.xml file commented out. You should use as a template to create new. (Be sure you include in the binary build its icon!)

As for the category: I think the non-KNIME nodes cannot add to existing (closed) categories, you can create your own or you can add under /community.

Cheers, gabor

Thank you Gabor!  This help alot but I was not able to get what I wanted.

Here is the plugin.xml code:

------------------------------

<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin>

   <!-- This is an example for providing an own category -->
      <extension
         point="org.knime.workbench.repository.categories">
      <category
            description="Category containing my nodes"
            icon="icons/default.png"
            level-id="myNodes"
            name="My nodes"
            path="/"/>
   </extension>
 
   
   <extension
         point="org.knime.workbench.repository.nodes">
      <node
            factory-class="org.optum.knime.readfasta.ReadFastNodeFactory"
            id="org.optum.knime.readfasta.ReadFastNodeFactory"/>
   </extension>
   
</plugin>

----------------------

Using the above code, the try to create a new category call "My nodes" but it was not created.

Instead, the node appear in the root directory.

Also, if I wanted to put a custom icon, do you know where I can place the .png file within the knime folder structure.

Thanks,

Ky

You have to set the category-path of your node to "/myNodes" (if there are multiple nodes in that category, it is also ok to add after property with the id of an other node).

You can put anywhere your icon in your project, just be sure it gets exported to the binary build (see the Build tab when you open META-INF/MANIFEST.MF or the plugin.xml file with the Plug-in manifest editor) and is properly referenced in your plugin.xml file.