29 #ifndef CDPL_CHEM_FRAGMENTGENERATOR_HPP
30 #define CDPL_CHEM_FRAGMENTGENERATOR_HPP
111 unsigned int rule_id,
unsigned int atom1_label,
unsigned int atom2_label);
126 std::size_t frag1Idx;
127 std::size_t frag2Idx;
130 unsigned int atom1Label;
131 unsigned int atom2Label;
135 typedef std::vector<FragmentationRule> FragmentationRuleList;
136 typedef std::vector<ExcludePattern> ExcludePatternList;
137 typedef std::vector<FragmentLink> FragmentLinkList;
232 std::size_t start_idx)
const;
239 unsigned int atom1Label;
240 unsigned int atom2Label;
243 typedef std::vector<SplitBondData> SplitBondDataArray;
245 FragmentationRuleList fragRules;
246 ExcludePatternList exclPatterns;
247 FragmentLinkList fragLinks;
249 FragmentFilterFunction fragFilterFunc;
253 SplitBondDataArray splitBondData;
Definition of the type CDPL::Util::BitSet.
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::FragmentList.
Definition of the class CDPL::Chem::MolecularGraph.
Definition of the class CDPL::Chem::SubstructureSearch.
Atom.
Definition: Atom.hpp:52
Bond.
Definition: Bond.hpp:50
Definition: FragmentGenerator.hpp:81
ExcludePattern(const MolecularGraph::SharedPointer &match_ptn, unsigned int rule_id)
unsigned int getRuleID() const
void setMatchPattern(const MolecularGraph::SharedPointer &ptn)
void setRuleID(unsigned int id)
void setGeneric(bool generic)
ExcludePattern(const MolecularGraph::SharedPointer &match_ptn)
const MolecularGraph::SharedPointer & getMatchPattern() const
Definition: FragmentGenerator.hpp:107
const Bond & getBond() const
unsigned int getAtom2Label() const
std::size_t getFragment1Index() const
FragmentLink(std::size_t frag1_idx, std::size_t frag2_idx, const Bond &bond, unsigned int rule_id, unsigned int atom1_label, unsigned int atom2_label)
unsigned int getAtom1Label() const
unsigned int getRuleID() const
std::size_t getFragment2Index() const
Definition: FragmentGenerator.hpp:62
void setMatchPattern(const MolecularGraph::SharedPointer &ptn)
unsigned int getID() const
void setID(unsigned int id)
const MolecularGraph::SharedPointer & getMatchPattern() const
FragmentationRule(const MolecularGraph::SharedPointer &match_ptn, unsigned int id)
FragmentGenerator.
Definition: FragmentGenerator.hpp:54
void removeFragmentationRule(std::size_t idx)
void addExcludePattern(const MolecularGraph::SharedPointer &match_ptn, unsigned int rule_id)
FragmentLinkList::const_iterator ConstFragmentLinkIterator
Definition: FragmentGenerator.hpp:146
ConstFragmentLinkIterator getFragmentLinksBegin() const
ExcludePatternList::iterator ExcludePatternIterator
Definition: FragmentGenerator.hpp:144
FragmentationRule & getFragmentationRule(std::size_t idx)
bool splitBondsIncluded() const
FragmentationRuleIterator getFragmentationRulesBegin()
ConstFragmentationRuleIterator getFragmentationRulesBegin() const
void clearExcludePatterns()
FragmentationRuleIterator getFragmentationRulesEnd()
std::shared_ptr< FragmentGenerator > SharedPointer
Definition: FragmentGenerator.hpp:57
const FragmentLink & getFragmentLink(std::size_t idx) const
ConstFragmentationRuleIterator getFragmentationRulesEnd() const
const ExcludePattern & getExcludePattern(std::size_t idx) const
ConstExcludePatternIterator getExcludePatternsEnd() const
virtual ~FragmentGenerator()
Definition: FragmentGenerator.hpp:155
ConstFragmentLinkIterator getFragmentLinksEnd() const
std::size_t getNumFragmentLinks() const
FragmentationRuleList::const_iterator ConstFragmentationRuleIterator
Definition: FragmentGenerator.hpp:140
const FragmentFilterFunction & getFragmentFilterFunction() const
void setFragmentFilterFunction(const FragmentFilterFunction &func)
const FragmentationRule & getFragmentationRule(std::size_t idx) const
std::size_t getNumExcludePatterns() const
std::size_t getNumFragmentationRules() const
FragmentGenerator(const FragmentGenerator &gen)
FragmentGenerator & operator=(const FragmentGenerator &gen)
ExcludePatternIterator getExcludePatternsBegin()
void addFragmentationRule(const MolecularGraph::SharedPointer &match_ptn, unsigned int rule_id)
ConstExcludePatternIterator getExcludePatternsBegin() const
FragmentGenerator()
Constructs the FragmentGenerator instance.
void addExcludePattern(const ExcludePattern &excl_ptn)
ExcludePattern & getExcludePattern(std::size_t idx)
std::function< bool(const MolecularGraph &)> FragmentFilterFunction
Definition: FragmentGenerator.hpp:59
void addExcludePattern(const MolecularGraph::SharedPointer &match_ptn)
void includeSplitBonds(bool include)
FragmentationRuleList::iterator FragmentationRuleIterator
Definition: FragmentGenerator.hpp:141
void addFragmentationRule(const FragmentationRule &rule)
void clearFragmentationRules()
void generate(const MolecularGraph &molgraph, FragmentList &frag_list, bool append=false)
ExcludePatternIterator getExcludePatternsEnd()
void removeExcludePattern(std::size_t idx)
ExcludePatternList::const_iterator ConstExcludePatternIterator
Definition: FragmentGenerator.hpp:143
A data type for the storage of Chem::Fragment objects.
Definition: FragmentList.hpp:49
Fragment.
Definition: Fragment.hpp:52
MolecularGraph.
Definition: MolecularGraph.hpp:52
std::shared_ptr< MolecularGraph > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated MolecularGraph instances.
Definition: MolecularGraph.hpp:58
SubstructureSearch.
Definition: SubstructureSearch.hpp:64
CDPL_CHEM_API void splitIntoFragments(const MolecularGraph &molgraph, FragmentList &frag_list, const Util::BitSet &split_bond_mask, bool append=false)
boost::dynamic_bitset BitSet
A dynamic bitset class.
Definition: BitSet.hpp:46
The namespace of the Chemical Data Processing Library.