CDKMCS { public static List<List<CDKRMap>> getSubgraphAtomsMaps(IAtomContainer sourceGraph, IAtomContainer targetGraph, boolean shouldMatchBonds) throws CDKException { List<CDKRMap> list = checkSingleAtomCases(sourceGraph, targetGraph); if (list == null) { return makeAtomsMapsOfBondsMaps(CDKMCS.getSubgraphMaps(sourceGraph, targetGraph, shouldMatchBonds), sourceGraph, targetGraph); } else { List<List<CDKRMap>> atomsMap = new ArrayList<List<CDKRMap>>(); atomsMap.add(list); return atomsMap; } }  static boolean isIsomorph(IAtomContainer sourceGraph, IAtomContainer targetGraph, boolean shouldMatchBonds); static List<CDKRMap> getIsomorphMap(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static List<CDKRMap> getIsomorphAtomsMap(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static List<List<CDKRMap>> getIsomorphMaps(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static List<List<CDKRMap>> getSubgraphMaps(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static List<CDKRMap> getSubgraphMap(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static List<List<CDKRMap>> getSubgraphAtomsMaps(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static List<CDKRMap> getSubgraphAtomsMap(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static boolean isSubgraph(IAtomContainer sourceGraph, IAtomContainer targetGraph, boolean shouldMatchBonds); static List<IAtomContainer> getOverlaps(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            boolean shouldMatchBonds); static BitSet getBitSet(IAtomContainer atomContainer); static CDKRGraph buildRGraph(IAtomContainer sourceGraph, IAtomContainer targetGraph, boolean shouldMatchBonds); static List<List<CDKRMap>> search(IAtomContainer sourceGraph, IAtomContainer targetGraph,
            BitSet sourceBitSet, BitSet targetBitSet, boolean findAllStructure, boolean findAllMap,
            boolean shouldMatchBonds); static IAtomContainer project(List<CDKRMap> rMapList, IAtomContainer graph, int key); static ArrayList<IAtomContainer> projectList(List<List<CDKRMap>> rMapsList, IAtomContainer graph, int key); static List<CDKRMap> checkSingleAtomCases(IAtomContainer sourceGraph, IAtomContainer targetGraph); static List<List<CDKRMap>> makeAtomsMapsOfBondsMaps(List<List<CDKRMap>> list, IAtomContainer sourceGraph,
            IAtomContainer targetGraph); static List<CDKRMap> makeAtomsMapOfBondsMap(List<CDKRMap> list, IAtomContainer sourceGraph,
            IAtomContainer targetGraph); synchronized static boolean isTimeOut();  }
@Test public void testGetSubgraphAtomsMaps_IAtomContainer() throws java.lang.Exception { int[] result1 = {6, 5, 7, 8, 0}; int[] result2 = {3, 4, 2, 1, 0}; IAtomContainer mol = TestMoleculeFactory.makeIndole(); IAtomContainer frag1 = TestMoleculeFactory.makePyrrole(); AtomContainerManipulator.percieveAtomTypesAndConfigureAtoms(mol); AtomContainerManipulator.percieveAtomTypesAndConfigureAtoms(frag1); CDKHydrogenAdder adder = CDKHydrogenAdder.getInstance(mol.getBuilder()); adder.addImplicitHydrogens(mol); adder = CDKHydrogenAdder.getInstance(frag1.getBuilder()); adder.addImplicitHydrogens(frag1); Aromaticity.cdkLegacy().apply(mol); Aromaticity.cdkLegacy().apply(frag1); List<List<CDKRMap>> list = CDKMCS.getSubgraphAtomsMaps(mol, frag1, true); List<CDKRMap> first = list.get(0); for (int i = 0; i < first.size(); i++) { CDKRMap rmap = first.get(i); Assert.assertEquals(rmap.getId1(), result1[i]); Assert.assertEquals(rmap.getId2(), result2[i]); } }