29 #ifndef CDPL_CHEM_TAUTOMERGENERATOR_HPP
30 #define CDPL_CHEM_TAUTOMERGENERATOR_HPP
35 #include <unordered_set>
153 void initHashCalculator();
161 bool addNewTautomer(
const MoleculePtr& mol_ptr);
162 bool outputTautomer(
const MoleculePtr& mol_ptr);
164 std::uint64_t calcConTabHashCode(
const MolecularGraph& molgraph,
bool arom_bonds);
170 typedef std::array<std::size_t, 3> BondDescriptor;
171 typedef std::vector<MoleculePtr> MoleculeList;
172 typedef std::vector<TautomerizationRule::SharedPointer> TautRuleList;
173 typedef std::vector<BondDescriptor> BondDescrArray;
174 typedef std::vector<std::size_t> SizeTArray;
175 typedef std::unordered_set<std::uint64_t> HashCodeSet;
176 typedef std::array<std::size_t, 6> StereoCenter;
177 typedef std::vector<StereoCenter> StereoCenterList;
184 bool remResDuplicates;
188 TautRuleList tautRules;
189 MoleculeList currGeneration;
190 MoleculeList nextGeneration;
191 StereoCenterList atomStereoCenters;
192 StereoCenterList bondStereoCenters;
193 HashCodeSet intermTautHashCodes;
194 HashCodeSet outputTautHashCodes;
198 BondDescrArray tautomerBonds;
Definition of the class CDPL::Chem::AromaticSubstructure.
Definition of the class CDPL::Chem::BasicMolecule.
Definition of the class CDPL::Chem::CIPConfigurationLabeler.
Definition of the preprocessor macro CDPL_CHEM_API.
#define CDPL_CHEM_API
Tells the compiler/linker which classes, functions and variables are part of the library API.
Definition of the class CDPL::Chem::HashCodeCalculator.
Definition of the class CDPL::Util::ObjectPool.
Definition of the class CDPL::Chem::TautomerizationRule.
Implements the perception of aromatic atoms and bonds in a molecular graph.
Definition: AromaticSubstructure.hpp:52
CIPConfigurationLabeler.
Definition: CIPConfigurationLabeler.hpp:55
HashCodeCalculator.
Definition: HashCodeCalculator.hpp:57
MolecularGraph.
Definition: MolecularGraph.hpp:52
TautomerGenerator.
Definition: TautomerGenerator.hpp:59
std::shared_ptr< TautomerGenerator > SharedPointer
Definition: TautomerGenerator.hpp:70
bool coordinates3DCleared() const
bool resonanceDuplicatesRemoved() const
void setCallbackFunction(const CallbackFunction &func)
TautomerGenerator()
Constructs the TautomerGenerator instance.
bool isotopesRegarded() const
std::size_t getNumTautomerizationRules() const
virtual ~TautomerGenerator()
Definition: TautomerGenerator.hpp:82
bool stereochemistryRegarded() const
void clearCoordinates3D(bool clear)
void regardStereochemistry(bool regard)
TautomerGenerator(const TautomerGenerator &gen)
std::function< bool(MolecularGraph &)> CallbackFunction
Definition: TautomerGenerator.hpp:72
const TautomerizationRule::SharedPointer & getTautomerizationRule(std::size_t idx) const
void generate(const MolecularGraph &molgraph)
Generates all unique tautomers of the molecular graph molgraph.
void removeResonanceDuplicates(bool remove)
void removeTautomerizationRule(std::size_t idx)
Mode
Definition: TautomerGenerator.hpp:63
@ TOPOLOGICALLY_UNIQUE
Definition: TautomerGenerator.hpp:65
@ GEOMETRICALLY_UNIQUE
Definition: TautomerGenerator.hpp:66
bool coordinates2DCleared() const
void addTautomerizationRule(const TautomerizationRule::SharedPointer &rule)
void clearCoordinates2D(bool clear)
void setCustomSetupFunction(const CustomSetupFunction &func)
void regardIsotopes(bool regard)
const CallbackFunction & getCallbackFunction() const
std::function< void(MolecularGraph &)> CustomSetupFunction
Definition: TautomerGenerator.hpp:73
TautomerGenerator & operator=(const TautomerGenerator &gen)
std::shared_ptr< TautomerizationRule > SharedPointer
Definition: TautomerizationRule.hpp:53
std::shared_ptr< ObjectType > SharedObjectPointer
Definition: ObjectPool.hpp:65
CDPL_CHEM_API void setAromaticityFlags(MolecularGraph &molgraph, bool overwrite)
The namespace of the Chemical Data Processing Library.