1 #ifndef CASM_SuperConfigEnum
2 #define CASM_SuperConfigEnum
33 template<
typename ConfigIterator>
39 template<
typename ConfigIterator>
46 std::string
name()
const override {
157 template<
typename ConfigIterator>
164 _target_scel.permute_begin(),
165 _target_scel.permute_end()) {}
169 template<
typename ConfigIterator>
175 m_target_scel(_target_scel),
176 m_sub_config(_begin, _end),
177 m_perm_begin(_perm_begin),
178 m_perm_end(_perm_end) {
SuperConfigEnum(Supercell &_target_scel, ConfigIterator _begin, ConfigIterator _end)
Constructor, using all Supercell permutations.
CASM::EnumInterfaceBase * make_SuperConfigEnum_interface()
A Counter allows looping over many incrementing variables in one loop.
const PermuteIterator & _perm_begin() const
std::vector< std::vector< Index > > m_index_map
m_current->occ(m_index_map[i][j]) = m_sub_scel[i].occ(j)
const std::vector< Configuration > & sub_config() const
Access the sub-configurations.
Base class for generic use of enumerators that may be accessed through the API.
PermuteIterator m_perm_end
notstd::cloneable_ptr< Configuration > m_current
The 'current' Configuration.
Counter< Array< int > > m_counter
Given a selection of Configurations, enumerate all tilings into some supercell.
Represents a supercell of the primitive parent crystal structure.
const PermuteIterator & _perm_end() const
bool _check_current() const
Returns true if current() satisifies requested conditions.
static const std::string enumerator_name
std::string name() const override
Derived enumerators must implement name, via ENUM_MEMBERS.
Supercell & m_target_scel
The supercell being filled.
void _init()
Used by constructor.
std::vector< Configuration > & _sub_config()
Access the sub-configurations.
PrimClex is the top-level data structure for a CASM project.
void increment() override
Implement increment.
std::vector< Configuration > m_sub_config
A vector containing each possible sub_config.
PermuteIterator m_perm_begin
Supercell & _sub_supercell()
Access the sub-config supercell.
const Array< int > & counter() const
Access the current value of the counter.
PrimGrid & _prim_grid()
Access the PrimGrid.
void _fill(const Array< int > &counter_val, Configuration &config)
static int run(PrimClex &primclex, const jsonParser &kwargs, const Completer::EnumOption &enum_opt)
const PrimGrid & prim_grid() const
Access the PrimGrid.
Supercell & _target_supercell()
Access the super-config supercell.
static const std::string interface_help
A Configuration represents the values of all degrees of freedom in a Supercell.
notstd::cloneable_ptr< PrimGrid > m_prim_grid
A PrimGrid that tiles thes sub_scel into the ref_scel.