3.19 OEMCSMaxAtoms

class OEMCSMaxAtoms : public OEMCSFunc
The OEMCSMaxAtoms class is an implementation of OEMCSFunc designed to order maximum common substructure matches by the maximum number of atoms included in the graph match. If two common structure matches having the same number of atoms, ties are split based on the number of bonds contained in the match.

double operator()(const OEMolBase &pattern,
                  const OEMolBase &target,
                  OEAtomBase **atoms,
                  OEBondBase **bonds)

This method is called by its parent OEMCSSearch instance. The method is called with the pattern molecule, target molecule, and arrays and atoms and bonds containing the correspondences found for the a common structure match. The method computes a value based on the number of atoms and bonds in the common structure match which is used to determine the maximum common structure match.

OEMCSFunc *CreateCopy() const
Deep copy constructor. This method returns an OEMCSMaxAtoms instance. The memory for the returned instance is allocated dynamically. The operator delete method should be called for the returned instance to prevent a memory leak.