Chemical Data Processing Library C++ API - Version 1.4.0
Public Types | Public Member Functions | List of all members
CDPL::Chem::TautomerizationRule Class Referenceabstract

Abstract base class for all tautomerization rule implementations used by the Chem::TautomerGenerator. More...

#include <TautomerizationRule.hpp>

+ Inheritance diagram for CDPL::Chem::TautomerizationRule:

Public Types

typedef std::shared_ptr< TautomerizationRuleSharedPointer
 A reference-counted smart pointer [SHPTR] for dynamically allocated TautomerizationRule instances. More...
 

Public Member Functions

virtual ~TautomerizationRule ()
 Virtual destructor. More...
 
virtual bool setup (MolecularGraph &parent_molgraph)=0
 Sets the parent molecular graph for which the rule is to enumerate tautomers. More...
 
virtual unsigned int getID () const =0
 Returns the rule's identifier (see Chem::TautomerizationType). More...
 
virtual bool generate (Molecule &tautomer)=0
 Generates the next tautomer. More...
 
virtual SharedPointer clone () const =0
 Returns a deep copy of this rule instance. More...
 

Detailed Description

Abstract base class for all tautomerization rule implementations used by the Chem::TautomerGenerator.

Member Typedef Documentation

◆ SharedPointer

A reference-counted smart pointer [SHPTR] for dynamically allocated TautomerizationRule instances.

Constructor & Destructor Documentation

◆ ~TautomerizationRule()

virtual CDPL::Chem::TautomerizationRule::~TautomerizationRule ( )
inlinevirtual

Virtual destructor.

Member Function Documentation

◆ setup()

virtual bool CDPL::Chem::TautomerizationRule::setup ( MolecularGraph parent_molgraph)
pure virtual

Sets the parent molecular graph for which the rule is to enumerate tautomers.

Parameters
parent_molgraphThe molecular graph to be tautomerized.
Returns
true if the rule applies to parent_molgraph and the iteration has been initialized, and false otherwise.

Implemented in CDPL::Chem::PatternBasedTautomerizationRule, and CDPL::Chem::ConjugatedRingBondPatternSwitching.

◆ getID()

virtual unsigned int CDPL::Chem::TautomerizationRule::getID ( ) const
pure virtual

Returns the rule's identifier (see Chem::TautomerizationType).

Returns
The rule identifier.

Implemented in CDPL::Chem::PatternBasedTautomerizationRule, and CDPL::Chem::ConjugatedRingBondPatternSwitching.

◆ generate()

virtual bool CDPL::Chem::TautomerizationRule::generate ( Molecule tautomer)
pure virtual

Generates the next tautomer.

Parameters
tautomerThe tautomer output molecule object.
Returns
true if a tautomer was generated, false if no more tautomers are available.

Implemented in CDPL::Chem::PatternBasedTautomerizationRule, and CDPL::Chem::ConjugatedRingBondPatternSwitching.

◆ clone()

virtual SharedPointer CDPL::Chem::TautomerizationRule::clone ( ) const
pure virtual

Returns a deep copy of this rule instance.

Returns
A shared pointer to the cloned rule.

Implemented in CDPL::Chem::PatternBasedTautomerizationRule, and CDPL::Chem::ConjugatedRingBondPatternSwitching.


The documentation for this class was generated from the following file: