@@ -77,7 +77,7 @@ any double bond to delocalized bonds (cMatchAromDBondToDelocalized cannot be use
7777 // - if an atom charge/mass is specified then this charge/mass must match for the atom to match
7878
7979 // defines details of similarity between atoms and bonds
80- private int mDefaultMatchMode ;
80+ private final int mDefaultMatchMode ;
8181
8282 // The molecule which is analyzed
8383 protected StereoMolecule mMolecule ;
@@ -111,7 +111,7 @@ any double bond to delocalized bonds (cMatchAromDBondToDelocalized cannot be use
111111
112112 // depending on the fragment count mode this may contain atom lists
113113 // of all till now located matching sub-fragments
114- private TreeSet <int []> mSortedMatchSet ;
114+ private final TreeSet <int []> mSortedMatchSet ;
115115 private ArrayList <int []> mMatchList ;
116116 private ArrayList <BridgeBond > mBridgeBondList ;
117117 private ArrayList <boolean []> mBridgeBondAtomList ;
@@ -229,10 +229,9 @@ public void setFragment(StereoMolecule fragment) {
229229 mFragmentAtomContextRank = null ;
230230
231231 if (mFragmentExcludeAtoms != 0 ) {
232- if (mFragmentExcludeAtoms != 0 )
233- for (int bond = 0 ; bond < mFragment .getBonds (); bond ++)
234- if (mIsExcludeAtom [mFragment .getBondAtom (0 , bond )] || mIsExcludeAtom [mFragment .getBondAtom (1 , bond )])
235- mFragmentExcludeBonds ++;
232+ for (int bond =0 ; bond <mFragment .getBonds (); bond ++)
233+ if (mIsExcludeAtom [mFragment .getBondAtom (0 , bond )] || mIsExcludeAtom [mFragment .getBondAtom (1 , bond )])
234+ mFragmentExcludeBonds ++;
236235
237236 // find all independent exclude groups
238237 for (int atom =0 ; atom <mFragment .getAllAtoms (); atom ++)
@@ -447,7 +446,7 @@ public int findFragmentInMolecule() {
447446 * sets of molecule atoms. Multiple matches involving the same atoms, e.g. with a benzene ring,
448447 * are counted and listed only once. If count mode is different from cCountModeExistance,
449448 * then an atom mapping from fragment to molecule is collected and can be retrieved with getMatchList().
450- * @param countMode one of cCountModeExistance, cCountModeFirstMatch, cCountModeOverlapping, cCountModeRigorous
449+ * @param countMode one of cCountModeExistance, cCountModeFirstMatch, cCountModeSeparated, cCountModeOverlapping, cCountModeUnique , cCountModeRigorous
451450 * @param matchMode cDefaultMatchMode or combination of cMatchAtomCharge, cMatchAtomMass, cMatchDBondToDelocalized, cMatchAromDBondToDelocalized
452451 * @return count of sub-structure matches of fragment in molecule
453452 */
@@ -1645,7 +1644,7 @@ else if (ringBonds == 3)
16451644 queryDefaults |= (Molecule .cAtomQFNotChargeNeg | Molecule .cAtomQFNotChargePos );
16461645 else if (charge < 0 )
16471646 queryDefaults |= (Molecule .cAtomQFNotCharge0 | Molecule .cAtomQFNotChargePos );
1648- else if ( charge > 0 )
1647+ else
16491648 queryDefaults |= (Molecule .cAtomQFNotCharge0 | Molecule .cAtomQFNotChargeNeg );
16501649
16511650 int hydrogens = mol .getAllHydrogens (atom );
@@ -1853,7 +1852,7 @@ private void buildBridgeBondList() {
18531852 }
18541853 }
18551854
1856- private class BridgeBond {
1855+ private static class BridgeBond {
18571856 int atom1 ,atom2 ,minBridgeSize ,maxBridgeSize ;
18581857 }
18591858
0 commit comments