There is a new KNIME forum. You can still browse and read content from our old forum but if you want to create new posts or join ongoing discussions, please visit our new KNIME forum: https://forum.knime.com

Importing from an additional jar file in Jython node

Member for

7 years 6 months baoilleach

Is it possible to import functions from a jar file when using the Jython nodes?

For example, in regular Jython I can add cdk-1.4.5.jar to the CLASSPATH and then "import org.openscience.cdk" will work.

If not currently possible, could I encourage this feature to be added as it would make it easy to use the CDK and Open Babel from Jython.

- Noel

Comments
Sat, 01/05/2013 - 11:44

Member for

9 years 3 months

gvanvuuren

This is an old post, but I'll reply for the record. What you're describing, works fine with the JPython nodes - you can add a jar with

 

sys.path.append(pathToJar)

 

and then you can do the import as usual.

 

Gideon