Package org.openscience.cdk.atomtype
Class StructGenMatcher
- java.lang.Object
-
- org.openscience.cdk.atomtype.StructGenMatcher
-
- All Implemented Interfaces:
IAtomTypeMatcher
public class StructGenMatcher extends Object implements IAtomTypeMatcher
AtomTypeMatcher that finds an AtomType by matching the Atom's element symbol. This atom type matcher takes into account formal charge and number of implicit hydrogens, and requires bond orders to be given.This class uses the cdk/config/data/structgen_atomtypes.xml list. If there is not an atom type defined for the tested atom, then null is returned.
- Author:
- egonw
- Source code:
- main
- Belongs to CDK module:
- structgen
- Created on:
- 2006-09-22
-
-
Constructor Summary
Constructors Constructor Description StructGenMatcher()
Constructor for the StructGenMatcher object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IAtomType
findMatchingAtomType(IAtomContainer atomContainer, IAtom atom)
Finds the AtomType matching the Atom's element symbol, formal charge and hybridization state.IAtomType[]
findMatchingAtomTypes(IAtomContainer atomContainer)
Method that assigns atom types to atoms in the given atom container.
-
-
-
Method Detail
-
findMatchingAtomTypes
public IAtomType[] findMatchingAtomTypes(IAtomContainer atomContainer) throws CDKException
Description copied from interface:IAtomTypeMatcher
Method that assigns atom types to atoms in the given atom container.- Specified by:
findMatchingAtomTypes
in interfaceIAtomTypeMatcher
- Parameters:
atomContainer
- AtomContainer for which atom types are perceived- Returns:
- The matching AtomType
- Throws:
CDKException
- when something went wrong with going through the AtomType's
-
findMatchingAtomType
public IAtomType findMatchingAtomType(IAtomContainer atomContainer, IAtom atom) throws CDKException
Finds the AtomType matching the Atom's element symbol, formal charge and hybridization state.- Specified by:
findMatchingAtomType
in interfaceIAtomTypeMatcher
- Parameters:
atomContainer
- AtomContaineratom
- the target atom- Returns:
- the matching AtomType
- Throws:
CDKException
- Exception thrown if something goes wrong
-
-