Hi all,
Thank you for this amazing library. I cam across the structure2name package, and decided to try the IUPACNameGenerator, which offers a capability I really need.
Unfortunately, I get a java.lang.NullPointerException when using the process function. See code below:
public class Test { public static void main(String[] args) throws Exception { IChemObjectBuilder builder = SilentChemObjectBuilder.getInstance(); SmilesParser smiParser = new SmilesParser(builder); IUPACNameGenerator iupacNG = new IUPACNameGenerator(); IAtomContainer atc = smiParser.parseSmiles("CC(=O)OC"); System.out.println(atc == null); System.out.println(iupacNG.generateIUPACName(atc)); } }
This code returns false on the atc==null test, and an exception:
Exception in thread "main" java.lang.NullPointerException at ambit2.structure2name.IUPACNameGenerator.generateIUPACName(IUPACNameGenerator.java:39) at camer.Test.main(Test.java:21)
Could you please help me solve this?
Best,
Yannick
Dear Yannick
Thank you for the interest with Ambit module structure2name
structure2name module is currently under development and it is a quite far way from being useable at all.
Hi Nikolay,
Thank you for your quick reply.
Best,
Yannick