CMLReader extends DefaultChemObjectReader { @Override public void setReader(Reader reader) throws CDKException { throw new CDKException("Invalid method call; use SetReader(InputStream) instead."); } CMLReader(InputStream input);  CMLReader();  CMLReader(String url); void registerConvention(String convention, ICMLModule conv); @Override IResourceFormat getFormat(); @Override void setReader(Reader reader); @Override void setReader(InputStream input); @Override boolean accepts(Class<? extends IChemObject> classObject); @Override T read(T object); @Override void close();  }
@Test(expected = CDKException.class) @Override public void testSetReader_Reader() throws Exception { InputStream ins = ChemObjectReaderTest.class.getClassLoader().getResourceAsStream(testFile); chemObjectIO.setReader(new InputStreamReader(ins)); }