Chemical Data Processing Library Python API - Version 1.4.0
Classes | Public Member Functions | List of all members
CDPL.Chem.PatternBasedTautomerizationRule Class Reference

Substructure search pattern-based implementation of the Chem.TautomerizationRule interface. More...

+ Inheritance diagram for CDPL.Chem.PatternBasedTautomerizationRule:

Classes

class  BondOrderChange
 Encodes a single bond order change between two pattern atoms applied when the parent transformation pattern matches. More...
 

Public Member Functions

None __init__ (int id)
 Initializes the PatternBasedTautomerizationRule instance. More...
 
None __init__ (PatternBasedTautomerizationRule rule)
 Constructs a PatternBasedTautomerizationRule instance that is copy of rule. More...
 
None addTransformationPattern (MolecularGraph molgraph, object bond_chgs)
 
None addExcludePattern (MolecularGraph molgraph)
 Registers a rule exclude pattern. More...
 
None addExcludePatterns (PatternBasedTautomerizationRule rule)
 Appends all registered search patterns of rule to the exclude pattern list of this rule. More...
 
None clearExcludePatterns ()
 Removes all registered exclude patterns.
 
PatternBasedTautomerizationRule assign (PatternBasedTautomerizationRule rule)
 Replaces the state of this rule by a copy of the state of rule. More...
 
- Public Member Functions inherited from CDPL.Chem.TautomerizationRule
None __init__ ()
 Initializes the TautomerizationRule instance.
 
int getObjectID ()
 Returns the numeric identifier (ID) of the wrapped C++ class instance. More...
 
int getID ()
 Returns the rule identifier. More...
 
bool setup (MolecularGraph parent_molgraph)
 Performs rule-specific setup work for the given molecular graph that shall be tautomerized. More...
 
bool generate (Molecule tautomer)
 Generates the next tautomer of the parent molecular graph and stores it in molecule. More...
 
TautomerizationRule clone ()
 Returns a deep copy of this rule instance. More...
 

Additional Inherited Members

- Properties inherited from CDPL.Chem.TautomerizationRule
 objectID = property(getObjectID)
 

Detailed Description

Substructure search pattern-based implementation of the Chem.TautomerizationRule interface.

The rule is configured with a set of transformation patterns describing the source substructure together with per-atom pair bond order changes that apply when the pattern matches plus optional exclude patterns (substructures that, when present, suppress the application of the rule). The setup() / generate() pair from the base class then enumerates the tautomers reachable from the parent molecular graph by applying the configured transformations.

Constructor & Destructor Documentation

◆ __init__() [1/2]

None CDPL.Chem.PatternBasedTautomerizationRule.__init__ ( int  id)

Initializes the PatternBasedTautomerizationRule instance.

Parameters
id

◆ __init__() [2/2]

None CDPL.Chem.PatternBasedTautomerizationRule.__init__ ( PatternBasedTautomerizationRule  rule)

Constructs a PatternBasedTautomerizationRule instance that is copy of rule.

Parameters
ruleThe other rule to copy.

Member Function Documentation

◆ addExcludePattern()

None CDPL.Chem.PatternBasedTautomerizationRule.addExcludePattern ( MolecularGraph  molgraph)

Registers a rule exclude pattern.

Any matching substructures present in the parent molecular graph will be excluded from structure transformations.

Parameters
molgraphThe exclude match pattern.

◆ addExcludePatterns()

None CDPL.Chem.PatternBasedTautomerizationRule.addExcludePatterns ( PatternBasedTautomerizationRule  rule)

Appends all registered search patterns of rule to the exclude pattern list of this rule.

Parameters
ruleThe source rule whose search patterns shall be added.

◆ assign()

PatternBasedTautomerizationRule CDPL.Chem.PatternBasedTautomerizationRule.assign ( PatternBasedTautomerizationRule  rule)

Replaces the state of this rule by a copy of the state of rule.

Parameters
ruleThe other rule to copy.
Returns
self