1 #ifndef CASM_ScelDatabase
2 #define CASM_ScelDatabase
38 iterator begin()
const override;
40 iterator end()
const override;
44 std::pair<iterator, bool> insert(
const Supercell &obj)
override;
45 std::pair<iterator, bool> insert(
const Supercell &&obj)
override;
48 template <
typename... Args>
49 std::pair<iterator, bool>
emplace(Args &&... args) {
50 return _on_insert_or_emplace(
51 m_scel_list.emplace(std::forward<Args>(args)...));
55 iterator erase(iterator pos)
override;
57 iterator
find(
const std::string &name_or_alias)
const override;
63 std::pair<iterator, bool> _on_insert_or_emplace(
64 const std::pair<base_iterator, bool> &result);
std::pair< iterator, bool > emplace(Args &&... args)
std::map< std::string, base_iterator > m_name_to_scel
std::set< Supercell >::iterator base_iterator
std::set< Supercell > m_scel_list
Database(const PrimClex &_primclex)
Generic interface for database of a particular CASM type.
PrimClex is the top-level data structure for a CASM project.
Represents a supercell of the primitive parent crystal structure.
Iterator find(Iterator begin, Iterator end, const T &value, BinaryCompare q)
Equivalent to std::find(begin, end, value), but with custom comparison.