1 #ifndef CASM_SuperConfigEnum
2 #define CASM_SuperConfigEnum
34 template <
typename ConfigIterator>
39 std::string
name()
const override;
113 template <
typename ConfigIterator>
117 : m_target_scel(_target_scel),
118 m_sub_config(sub_config_begin, sub_config_end) {
Basic std::vector like container (deprecated)
A Counter allows looping over many incrementing variables in one loop.
Given a selection of Configurations, enumerate all tilings into some supercell.
xtal::UnitCellIndexConverter & _unitcell_index_converter()
Access the UnitCellIndexConverter.
Supercell const & _sub_supercell() const
Access the sub-config supercell.
Array< int > const & counter() const
Access the current value of the counter.
Counter< Array< int > > m_counter
void increment() override
Implement increment.
Supercell const & m_target_scel
The supercell being filled.
Supercell const & _target_supercell()
Access the super-config supercell.
std::string name() const override
Derived enumerators must implement name, via ENUM_MEMBERS.
notstd::cloneable_ptr< xtal::UnitCellIndexConverter > m_unitcell_index_converter
std::vector< Configuration > & _sub_config()
Access the sub-configurations.
void _fill(Array< int > const &counter_val, Configuration &config)
Supercell const * m_sub_scel
notstd::cloneable_ptr< Configuration > m_current
The 'current' Configuration.
SuperConfigEnum(Supercell const &_target_scel, ConfigIterator sub_config_begin, ConfigIterator sub_config_end)
Constructor, using all Supercell permutations.
bool _check_current() const
Returns true if current() satisifies requested conditions.
std::vector< std::vector< Index > > m_index_map
m_current->occ(m_index_map[i][j]) = m_sub_scel[i].occ(j)
void _init()
Used by constructor.
std::vector< Configuration > const & sub_config() const
Access the sub-configurations.
std::vector< Configuration > m_sub_config
A vector containing each possible sub_config.
static const std::string enumerator_name
Represents a supercell of the primitive parent crystal structure.
A 'cloneable_ptr' can be used in place of 'unique_ptr'.
ConfigIO::GenericConfigFormatter< jsonParser > config()