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(TemplateHandlerTest.class)
test_class.modifier: private static
test_class.original_string: private static ILoggingTool              logger     = LoggingToolFactory
                                                                  .createLoggingTool(TemplateHandlerTest.class);
test_class.type: ILoggingTool
test_class.var_name: logger
test_class.declarator: sp         = null
test_class.modifier: private static
test_class.original_string: private static SmilesParser              sp         = null;
test_class.type: SmilesParser
test_class.var_name: sp
test_class.declarator: sdg        = null
test_class.modifier: private static
test_class.original_string: private static StructureDiagramGenerator sdg        = null;
test_class.type: StructureDiagramGenerator
test_class.var_name: sdg
test_class.file: tool/sdg/src/test/java/org/openscience/cdk/layout/TemplateHandlerTest.java
test_class.identifier: TemplateHandlerTest
test_class.superclass: extends CDKTestCase
test_case.body: @Test
      public void testOtherBondOrder() throws Exception {
          boolean itIsInThere = false;
          TemplateHandler th = new TemplateHandler(DefaultChemObjectBuilder.getInstance());
          IAtomContainer mol = TestMoleculeFactory.makeSteran();
          itIsInThere = th.mapTemplates(mol);
          Assert.assertTrue(itIsInThere);
          mol.getBond(0).setOrder(IBond.Order.DOUBLE);
          itIsInThere = th.mapTemplates(mol);
          Assert.assertTrue(itIsInThere);
      }
test_case.class_method_signature: TemplateHandlerTest.testOtherBondOrder()
test_case.full_signature: @Test public void testOtherBondOrder()
test_case.identifier: testOtherBondOrder
test_case.invocations: getInstance makeSteran mapTemplates assertTrue setOrder getBond mapTemplates assertTrue
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testOtherBondOrder()
focal_class.declarator: LOGGER       = LoggingToolFactory.createLoggingTool(TemplateHandler.class)
focal_class.modifier: private final static
focal_class.original_string: private final static ILoggingTool         LOGGER       = LoggingToolFactory.createLoggingTool(TemplateHandler.class);
focal_class.type: ILoggingTool
focal_class.var_name: LOGGER
focal_class.declarator: templates    = new ArrayList<>()
focal_class.modifier: private final
focal_class.original_string: private final        List<IAtomContainer> templates    = new ArrayList<>();
focal_class.type: List<IAtomContainer>
focal_class.var_name: templates
focal_class.declarator: anonPatterns = new ArrayList<>()
focal_class.modifier: private final
focal_class.original_string: private final        List<Pattern>        anonPatterns = new ArrayList<>();
focal_class.type: List<Pattern>
focal_class.var_name: anonPatterns
focal_class.declarator: elemPatterns = new ArrayList<>()
focal_class.modifier: private final
focal_class.original_string: private final        List<Pattern>        elemPatterns = new ArrayList<>();
focal_class.type: List<Pattern>
focal_class.var_name: elemPatterns
focal_class.declarator: elemAtomMatcher = new AtomMatcher() {
          @Override
          public boolean matches(IAtom a, IAtom b) {
              return a.getAtomicNumber().equals(b.getAtomicNumber());
          }
      }
focal_class.modifier: private final
focal_class.original_string: private final AtomMatcher elemAtomMatcher = new AtomMatcher() {
          @Override
          public boolean matches(IAtom a, IAtom b) {
              return a.getAtomicNumber().equals(b.getAtomicNumber());
          }
      };
focal_class.type: AtomMatcher
focal_class.var_name: elemAtomMatcher
focal_class.declarator: anonAtomMatcher = new AtomMatcher() {
          @Override
          public boolean matches(IAtom a, IAtom b) {
              return true;
          }
      }
focal_class.modifier: private final
focal_class.original_string: private final AtomMatcher anonAtomMatcher = new AtomMatcher() {
          @Override
          public boolean matches(IAtom a, IAtom b) {
              return true;
          }
      };
focal_class.type: AtomMatcher
focal_class.var_name: anonAtomMatcher
focal_class.declarator: anonBondMatcher = new BondMatcher() {
          @Override
          public boolean matches(IBond a, IBond b) {
              return true;
          }
      }
focal_class.modifier: private final
focal_class.original_string: private final BondMatcher anonBondMatcher = new BondMatcher() {
          @Override
          public boolean matches(IBond a, IBond b) {
              return true;
          }
      };
focal_class.type: BondMatcher
focal_class.var_name: anonBondMatcher
focal_class.file: tool/sdg/src/main/java/org/openscience/cdk/layout/TemplateHandler.java
focal_class.identifier: TemplateHandler
focal_class.class_method_signature: TemplateHandler.TemplateHandler(IChemObjectBuilder builder)
focal_class.full_signature: public  TemplateHandler(IChemObjectBuilder builder)
focal_class.identifier: TemplateHandler
focal_class.modifiers: public
focal_class.parameters: (IChemObjectBuilder builder)
focal_class.signature:  TemplateHandler(IChemObjectBuilder builder)
focal_class.class_method_signature: TemplateHandler.TemplateHandler()
focal_class.full_signature: public  TemplateHandler()
focal_class.identifier: TemplateHandler
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  TemplateHandler()
focal_class.class_method_signature: TemplateHandler.loadTemplates(IChemObjectBuilder builder)
focal_class.full_signature: public void loadTemplates(IChemObjectBuilder builder)
focal_class.identifier: loadTemplates
focal_class.modifiers: public
focal_class.parameters: (IChemObjectBuilder builder)
focal_class.return: void
focal_class.signature: void loadTemplates(IChemObjectBuilder builder)
focal_class.class_method_signature: TemplateHandler.addMolecule(IAtomContainer molecule)
focal_class.full_signature: public void addMolecule(IAtomContainer molecule)
focal_class.identifier: addMolecule
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer molecule)
focal_class.return: void
focal_class.signature: void addMolecule(IAtomContainer molecule)
focal_class.class_method_signature: TemplateHandler.removeMolecule(IAtomContainer molecule)
focal_class.full_signature: public IAtomContainer removeMolecule(IAtomContainer molecule)
focal_class.identifier: removeMolecule
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer molecule)
focal_class.return: IAtomContainer
focal_class.signature: IAtomContainer removeMolecule(IAtomContainer molecule)
focal_class.class_method_signature: TemplateHandler.mapTemplateExact(IAtomContainer molecule)
focal_class.full_signature: public boolean mapTemplateExact(IAtomContainer molecule)
focal_class.identifier: mapTemplateExact
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer molecule)
focal_class.return: boolean
focal_class.signature: boolean mapTemplateExact(IAtomContainer molecule)
focal_class.class_method_signature: TemplateHandler.mapTemplates(IAtomContainer molecule)
focal_class.full_signature: public boolean mapTemplates(IAtomContainer molecule)
focal_class.identifier: mapTemplates
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer molecule)
focal_class.return: boolean
focal_class.signature: boolean mapTemplates(IAtomContainer molecule)
focal_class.class_method_signature: TemplateHandler.getTemplateCount()
focal_class.full_signature: public int getTemplateCount()
focal_class.identifier: getTemplateCount
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: int
focal_class.signature: int getTemplateCount()
focal_class.class_method_signature: TemplateHandler.getTemplateAt(int position)
focal_class.full_signature: public IAtomContainer getTemplateAt(int position)
focal_class.identifier: getTemplateAt
focal_class.modifiers: public
focal_class.parameters: (int position)
focal_class.return: IAtomContainer
focal_class.signature: IAtomContainer getTemplateAt(int position)
focal_class.class_method_signature: TemplateHandler.getMappedSubstructures(IAtomContainer molecule)
focal_class.full_signature: public IAtomContainerSet getMappedSubstructures(IAtomContainer molecule)
focal_class.identifier: getMappedSubstructures
focal_class.modifiers: public
focal_class.parameters: (IAtomContainer molecule)
focal_class.return: IAtomContainerSet
focal_class.signature: IAtomContainerSet getMappedSubstructures(IAtomContainer molecule)
focal_class.class_method_signature: TemplateHandler.createSingleton(IAtomContainer template)
focal_class.full_signature: public static TemplateHandler createSingleton(IAtomContainer template)
focal_class.identifier: createSingleton
focal_class.modifiers: public static
focal_class.parameters: (IAtomContainer template)
focal_class.return: TemplateHandler
focal_class.signature: TemplateHandler createSingleton(IAtomContainer template)
focal_class.class_method_signature: TemplateHandler.createFromSubstructure(Pattern ptrn, Iterable<IAtomContainer> mols)
focal_class.full_signature: public static TemplateHandler createFromSubstructure(Pattern ptrn, Iterable<IAtomContainer> mols)
focal_class.identifier: createFromSubstructure
focal_class.modifiers: public static
focal_class.parameters: (Pattern ptrn, Iterable<IAtomContainer> mols)
focal_class.return: TemplateHandler
focal_class.signature: TemplateHandler createFromSubstructure(Pattern ptrn, Iterable<IAtomContainer> mols)
focal_class.class_method_signature: TemplateHandler.createFromSubstructure(Pattern ptrn, IAtomContainer mol)
focal_class.full_signature: public static TemplateHandler createFromSubstructure(Pattern ptrn, IAtomContainer mol)
focal_class.identifier: createFromSubstructure
focal_class.modifiers: public static
focal_class.parameters: (Pattern ptrn, IAtomContainer mol)
focal_class.return: TemplateHandler
focal_class.signature: TemplateHandler createFromSubstructure(Pattern ptrn, IAtomContainer mol)
focal_class.class_method_signature: TemplateHandler.toIdentityTemplateLibrary()
focal_class.full_signature:  IdentityTemplateLibrary toIdentityTemplateLibrary()
focal_class.identifier: toIdentityTemplateLibrary
focal_class.parameters: ()
focal_class.return: IdentityTemplateLibrary
focal_class.signature: IdentityTemplateLibrary toIdentityTemplateLibrary()
focal_method.body: public boolean mapTemplates(IAtomContainer molecule) throws CDKException {
          // match element patterns first so hetero atoms are oriented correctly
          for (Pattern anonPattern : elemPatterns) {
              for (Map<IAtom, IAtom> atoms : anonPattern.matchAll(molecule).toAtomMap()) {
                  for (Map.Entry<IAtom, IAtom> e : atoms.entrySet()) {
                      e.getValue().setPoint2d(new Point2d(e.getKey().getPoint2d()));
                      e.getValue().setFlag(CDKConstants.ISPLACED, true);
                  }
                  if (!atoms.isEmpty())
                      return true;
              }
          }
          // no element pattern matched, try anonymous patterns
          for (Pattern anonPattern : anonPatterns) {
              for (Map<IAtom, IAtom> atoms : anonPattern.matchAll(molecule).toAtomMap()) {
                  for (Map.Entry<IAtom, IAtom> e : atoms.entrySet()) {
                      e.getValue().setPoint2d(new Point2d(e.getKey().getPoint2d()));
                      e.getValue().setFlag(CDKConstants.ISPLACED, true);
                  }
                  if (!atoms.isEmpty())
                      return true;
              }
          }
          return false;
      }
focal_method.class_method_signature: TemplateHandler.mapTemplates(IAtomContainer molecule)
focal_method.full_signature: public boolean mapTemplates(IAtomContainer molecule)
focal_method.identifier: mapTemplates
focal_method.invocations: toAtomMap matchAll entrySet setPoint2d getValue getPoint2d getKey setFlag getValue isEmpty toAtomMap matchAll entrySet setPoint2d getValue getPoint2d getKey setFlag getValue isEmpty
focal_method.modifiers: public
focal_method.parameters: (IAtomContainer molecule)
focal_method.return: boolean
focal_method.signature: boolean mapTemplates(IAtomContainer molecule)