test_class.declarator: standAlone = false
test_class.modifier: public
test_class.original_string: public boolean       standAlone = false;
test_class.type: boolean
test_class.var_name: standAlone
test_class.declarator: logger     = LoggingToolFactory.createLoggingTool(HydrogenPlacerTest.class)
test_class.modifier: private
test_class.original_string: private ILoggingTool logger     = LoggingToolFactory.createLoggingTool(HydrogenPlacerTest.class);
test_class.type: ILoggingTool
test_class.var_name: logger
test_class.file: tool/sdg/src/test/java/org/openscience/cdk/layout/HydrogenPlacerTest.java
test_class.identifier: HydrogenPlacerTest
test_class.superclass: extends CDKTestCase
test_case.body: @Test
      public void testPlaceHydrogens2D() throws Exception {
          HydrogenPlacer hydrogenPlacer = new HydrogenPlacer();
          IAtomContainer dichloromethane = new AtomContainer();
          Atom carbon = new Atom("C");
          Point2d carbonPos = new Point2d(0.0, 0.0);
          carbon.setPoint2d(carbonPos);
          Atom h1 = new Atom("H");
          Atom h2 = new Atom("H");
          Atom cl1 = new Atom("Cl");
          Point2d cl1Pos = new Point2d(0.0, -1.0);
          cl1.setPoint2d(cl1Pos);
          Atom cl2 = new Atom("Cl");
          Point2d cl2Pos = new Point2d(-1.0, 0.0);
          cl2.setPoint2d(cl2Pos);
          dichloromethane.addAtom(carbon);
          dichloromethane.addAtom(h1);
          dichloromethane.addAtom(h2);
          dichloromethane.addAtom(cl1);
          dichloromethane.addAtom(cl2);
          dichloromethane.addBond(new Bond(carbon, h1));
          dichloromethane.addBond(new Bond(carbon, h2));
          dichloromethane.addBond(new Bond(carbon, cl1));
          dichloromethane.addBond(new Bond(carbon, cl2));
  
          Assert.assertNull(h1.getPoint2d());
          Assert.assertNull(h2.getPoint2d());
  
          // generate new coords
          hydrogenPlacer.placeHydrogens2D(dichloromethane, carbon);
          // check that previously set coordinates are kept
          assertEquals(carbonPos, carbon.getPoint2d(), 0.01);
          assertEquals(cl1Pos, cl1.getPoint2d(), 0.01);
          assertEquals(cl2Pos, cl2.getPoint2d(), 0.01);
          Assert.assertNotNull(h1.getPoint2d());
          Assert.assertNotNull(h2.getPoint2d());
      }
test_case.class_method_signature: HydrogenPlacerTest.testPlaceHydrogens2D()
test_case.full_signature: @Test public void testPlaceHydrogens2D()
test_case.identifier: testPlaceHydrogens2D
test_case.invocations: setPoint2d setPoint2d setPoint2d addAtom addAtom addAtom addAtom addAtom addBond addBond addBond addBond assertNull getPoint2d assertNull getPoint2d placeHydrogens2D assertEquals getPoint2d assertEquals getPoint2d assertEquals getPoint2d assertNotNull getPoint2d assertNotNull getPoint2d
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testPlaceHydrogens2D()
focal_class.declarator: logger = LoggingToolFactory.createLoggingTool(HydrogenPlacer.class)
focal_class.modifier: private static final
focal_class.original_string: private static final ILoggingTool logger = LoggingToolFactory.createLoggingTool(HydrogenPlacer.class);
focal_class.type: ILoggingTool
focal_class.var_name: logger
focal_class.file: tool/sdg/src/main/java/org/openscience/cdk/layout/HydrogenPlacer.java
focal_class.identifier: HydrogenPlacer
focal_class.class_method_signature: HydrogenPlacer.placeHydrogens2D(final IAtomContainer container, final double bondLength)
focal_class.full_signature: public void placeHydrogens2D(final IAtomContainer container, final double bondLength)
focal_class.identifier: placeHydrogens2D
focal_class.modifiers: public
focal_class.parameters: (final IAtomContainer container, final double bondLength)
focal_class.return: void
focal_class.signature: void placeHydrogens2D(final IAtomContainer container, final double bondLength)
focal_class.class_method_signature: HydrogenPlacer.placeHydrogens2D(IAtomContainer container, IAtom atom)
focal_class.full_signature: public void placeHydrogens2D(IAtomContainer container, IAtom atom)
focal_class.identifier: placeHydrogens2D
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer container, IAtom atom)
focal_class.return: void
focal_class.signature: void placeHydrogens2D(IAtomContainer container, IAtom atom)
focal_class.class_method_signature: HydrogenPlacer.placeHydrogens2D(IAtomContainer container, IAtom atom, double bondLength)
focal_class.full_signature: public void placeHydrogens2D(IAtomContainer container, IAtom atom, double bondLength)
focal_class.identifier: placeHydrogens2D
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer container, IAtom atom, double bondLength)
focal_class.return: void
focal_class.signature: void placeHydrogens2D(IAtomContainer container, IAtom atom, double bondLength)
focal_method.body: public void placeHydrogens2D(final IAtomContainer container, final double bondLength) {
          logger.debug("placing hydrogens on all atoms");
          for (IAtom atom : container.atoms()) {
              // only place hydrogens for atoms which have coordinates
              if (atom.getPoint2d() != null) {
                  placeHydrogens2D(container, atom, bondLength);
              }
          }
          logger.debug("hydrogen placement complete");
      }
focal_method.class_method_signature: HydrogenPlacer.placeHydrogens2D(final IAtomContainer container, final double bondLength)
focal_method.full_signature: public void placeHydrogens2D(final IAtomContainer container, final double bondLength)
focal_method.identifier: placeHydrogens2D
focal_method.invocations: debug atoms getPoint2d placeHydrogens2D debug
focal_method.modifiers: public
focal_method.parameters: (final IAtomContainer container, final double bondLength)
focal_method.return: void
focal_method.signature: void placeHydrogens2D(final IAtomContainer container, final double bondLength)