@Test public void testNameToStructure() { NameToStructure nts = NameToStructure.getInstance(); assertNotNull("Got a name to structure convertor", nts); }
private NameToStructure() { LOG.debug("Initialising OPSIN... "); try { ResourceGetter resourceGetter = new ResourceGetter("uk/ac/cam/ch/wwmm/opsin/resources/"); ResourceManager resourceManager = new ResourceManager(resourceGetter); WordRules wordRules = new WordRules(resourceGetter); parseRules = new ParseRules(resourceManager); Tokeniser tokeniser = new Tokeniser(parseRules); parser = new Parser(wordRules, tokeniser, resourceManager); suffixRules = new SuffixRules(resourceGetter); } catch (Exception e) { throw new NameToStructureException(e.getMessage(), e); } LOG.debug("OPSIN initialised"); }
NameToStructure { private NameToStructure() { LOG.debug("Initialising OPSIN... "); try { ResourceGetter resourceGetter = new ResourceGetter("uk/ac/cam/ch/wwmm/opsin/resources/"); ResourceManager resourceManager = new ResourceManager(resourceGetter); WordRules wordRules = new WordRules(resourceGetter); parseRules = new ParseRules(resourceManager); Tokeniser tokeniser = new Tokeniser(parseRules); parser = new Parser(wordRules, tokeniser, resourceManager); suffixRules = new SuffixRules(resourceGetter); } catch (Exception e) { throw new NameToStructureException(e.getMessage(), e); } LOG.debug("OPSIN initialised"); } }
NameToStructure { private NameToStructure() { LOG.debug("Initialising OPSIN... "); try { ResourceGetter resourceGetter = new ResourceGetter("uk/ac/cam/ch/wwmm/opsin/resources/"); ResourceManager resourceManager = new ResourceManager(resourceGetter); WordRules wordRules = new WordRules(resourceGetter); parseRules = new ParseRules(resourceManager); Tokeniser tokeniser = new Tokeniser(parseRules); parser = new Parser(wordRules, tokeniser, resourceManager); suffixRules = new SuffixRules(resourceGetter); } catch (Exception e) { throw new NameToStructureException(e.getMessage(), e); } LOG.debug("OPSIN initialised"); } private  NameToStructure(); }
NameToStructure { private NameToStructure() { LOG.debug("Initialising OPSIN... "); try { ResourceGetter resourceGetter = new ResourceGetter("uk/ac/cam/ch/wwmm/opsin/resources/"); ResourceManager resourceManager = new ResourceManager(resourceGetter); WordRules wordRules = new WordRules(resourceGetter); parseRules = new ParseRules(resourceManager); Tokeniser tokeniser = new Tokeniser(parseRules); parser = new Parser(wordRules, tokeniser, resourceManager); suffixRules = new SuffixRules(resourceGetter); } catch (Exception e) { throw new NameToStructureException(e.getMessage(), e); } LOG.debug("OPSIN initialised"); } private  NameToStructure(); static synchronized NameToStructure getInstance(); static String getVersion(); String parseToCML(String name); String parseToSmiles(String name); OpsinResult parseChemicalName(String name); OpsinResult parseChemicalName(String name, NameToStructureConfig n2sConfig); static ParseRules getOpsinParser(); static void main(String [] args); }
NameToStructure { private NameToStructure() { LOG.debug("Initialising OPSIN... "); try { ResourceGetter resourceGetter = new ResourceGetter("uk/ac/cam/ch/wwmm/opsin/resources/"); ResourceManager resourceManager = new ResourceManager(resourceGetter); WordRules wordRules = new WordRules(resourceGetter); parseRules = new ParseRules(resourceManager); Tokeniser tokeniser = new Tokeniser(parseRules); parser = new Parser(wordRules, tokeniser, resourceManager); suffixRules = new SuffixRules(resourceGetter); } catch (Exception e) { throw new NameToStructureException(e.getMessage(), e); } LOG.debug("OPSIN initialised"); } private  NameToStructure(); static synchronized NameToStructure getInstance(); static String getVersion(); String parseToCML(String name); String parseToSmiles(String name); OpsinResult parseChemicalName(String name); OpsinResult parseChemicalName(String name, NameToStructureConfig n2sConfig); static ParseRules getOpsinParser(); static void main(String [] args);  }