BondsToAtomDescriptor extends AbstractAtomicDescriptor implements IAtomicDescriptor { public BondsToAtomDescriptor() {} BondsToAtomDescriptor(); @Override DescriptorSpecification getSpecification(); @Override void setParameters(Object[] params); @Override Object[] getParameters(); @Override String[] getDescriptorNames(); @Override DescriptorValue calculate(IAtom atom, IAtomContainer container); @Override String[] getParameterNames(); @Override Object getParameterType(String name);  }
@Test public void testBondsToAtomDescriptor() throws ClassNotFoundException, CDKException, java.lang.Exception { BondsToAtomDescriptor descriptor = new BondsToAtomDescriptor(); Object[] params = {Integer.valueOf(5)}; descriptor.setParameters(params); SmilesParser sp = new SmilesParser(DefaultChemObjectBuilder.getInstance()); IAtomContainer mol = sp.parseSmiles("CCCCCC"); Assert.assertEquals(5, ((IntegerResult) descriptor.calculate(mol.getAtom(0), mol).getValue()).intValue()); }