29 #ifndef CDPL_BIOMOL_HIERARCHYVIEW_HPP
30 #define CDPL_BIOMOL_HIERARCHYVIEW_HPP
34 #include <unordered_map>
38 #include <boost/iterator/indirect_iterator.hpp>
57 typedef std::shared_ptr<HierarchyViewModel> ModelPtr;
58 typedef std::vector<ModelPtr> ModelList;
66 typedef boost::indirect_iterator<ModelList::const_iterator, const HierarchyViewModel>
ConstModelIterator;
104 void initModelList()
const;
106 typedef std::unordered_map<std::size_t, ModelPtr> IDToModelMap;
110 mutable ModelList models;
111 mutable IDToModelMap idToModelMap;
112 mutable bool initResidues;
113 mutable bool initModels;
114 mutable std::mutex initMutex;
Definition of the preprocessor macro CDPL_BIOMOL_API.
#define CDPL_BIOMOL_API
Tells the compiler/linker which classes, functions and variables are part of the library API.
Definition of the class CDPL::Biomol::HierarchyViewModel.
Definition of the class CDPL::Biomol::ResidueList.
HierarchyViewModel.
Definition: HierarchyViewModel.hpp:56
A data structure allowing a hierarchical view on biological macromolecules.
Definition: HierarchyView.hpp:55
const HierarchyViewModel & getModel(std::size_t idx) const
ConstModelIterator getModelsBegin() const
const HierarchyViewModel & getModelByNumber(std::size_t num) const
boost::indirect_iterator< ModelList::const_iterator, const HierarchyViewModel > ConstModelIterator
Definition: HierarchyView.hpp:66
const ResidueList & getResidues() const
HierarchyView()
Constructs an empty HierarchyView instance.
std::size_t getNumModels() const
void build(const Chem::MolecularGraph &molgraph)
Build the hierarchy view for the molecular graph molgraph.
ConstModelIterator begin() const
std::shared_ptr< HierarchyView > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated HierarchyView instances.
Definition: HierarchyView.hpp:64
ConstModelIterator getModelsEnd() const
HierarchyView(const Chem::MolecularGraph &molgraph)
Constructs a HierarchyView instance for the molecular graph molgraph.
bool hasModelWithNumber(std::size_t num) const
ConstModelIterator end() const
Implements the extraction of residues in biological macromolecules.
Definition: ResidueList.hpp:52
MolecularGraph.
Definition: MolecularGraph.hpp:52
The namespace of the Chemical Data Processing Library.