29 #ifndef CDPL_CONFGEN_FRAGMENTLIBRARY_HPP
30 #define CDPL_CONFGEN_FRAGMENTLIBRARY_HPP
34 #include <unordered_map>
51 typedef std::unordered_map<std::uint64_t, FragmentLibraryEntry::SharedPointer> HashToEntryMap;
56 typedef HashToEntryMap::value_type
Entry;
102 void save(std::ostream& os)
const;
114 mutable HashToEntryMap hashToEntryMap;
115 mutable std::mutex mutex;
Definition of the preprocessor macro CDPL_CONFGEN_API.
#define CDPL_CONFGEN_API
Tells the compiler/linker which classes, functions and variables are part of the library API.
Definition of the class CDPL::ConfGen::FragmentLibraryEntry.
std::shared_ptr< FragmentLibraryEntry > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated FragmentLibraryEntry instances.
Definition: FragmentLibraryEntry.hpp:59
Definition: FragmentLibrary.hpp:49
std::shared_ptr< FragmentLibrary > SharedPointer
Definition: FragmentLibrary.hpp:54
ConstEntryIterator end() const
std::size_t getNumEntries() const
HashToEntryMap::value_type Entry
Definition: FragmentLibrary.hpp:56
HashToEntryMap::iterator EntryIterator
Definition: FragmentLibrary.hpp:58
bool containsEntry(std::uint64_t hash_code) const
bool removeEntry(std::uint64_t hash_code)
static void set(const SharedPointer &lib)
const FragmentLibraryEntry::SharedPointer & getEntry(std::uint64_t hash_code) const
EntryIterator removeEntry(const EntryIterator &it)
static const SharedPointer & get()
void save(std::ostream &os) const
FragmentLibrary & operator=(const FragmentLibrary &lib)
FragmentLibrary(const FragmentLibrary &lib)
void addEntries(const FragmentLibrary &lib)
bool addEntry(const FragmentLibraryEntry::SharedPointer &entry)
ConstEntryIterator getEntriesBegin() const
EntryIterator getEntriesBegin()
ConstEntryIterator getEntriesEnd() const
void load(std::istream &is)
HashToEntryMap::const_iterator ConstEntryIterator
Definition: FragmentLibrary.hpp:57
EntryIterator getEntriesEnd()
ConstEntryIterator begin() const
The namespace of the Chemical Data Processing Library.