CASM
AClustersApproachtoStatisticalMechanics
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules
CASM::Completer::EnumOption Class Reference

#include <Handlers.hh>

+ Inheritance diagram for CASM::Completer::EnumOption:

Detailed Description

Options set for casm enum. Enumerate configurations and supercells here.

Definition at line 811 of file Handlers.hh.

Public Member Functions

 EnumOption ()
 
const std::vector< std::string > & desc_vec () const
 
std::string method () const
 
int min_volume () const
 
int max_volume () const
 
bool all_existing () const
 
const std::vector< std::string > & filter_strs () const
 
po::variables_map & vm ()
 Get the variables map. More...
 
const po::variables_map & vm () const
 Get the variables map. More...
 
const po::options_description & desc ()
 Get the program options, filled with the initialized values. More...
 
const std::string & tag () const
 The desired name for the casm option (Perhaps this should get tied with CommandArg?) More...
 

Protected Member Functions

void add_configlist_suboption (const fs::path &_default="MASTER")
 Add –config suboption (defaults to MASTER) More...
 
const fs::path & selection_path () const
 Returns the string corresponding to add_config_suboption() More...
 
void add_configlists_suboption (const fs::path &_default="MASTER")
 Add –configs suboption (defaults to MASTER) More...
 
const std::vector< fs::path > & selection_paths () const
 Returns the string corresponding to add_config_suboption() More...
 
void add_configlist_nodefault_suboption ()
 Add –config suboption (no default) More...
 
void add_configlists_nodefault_suboption ()
 Add –configs suboption (no default) More...
 
void add_help_suboption ()
 Add a plain –help suboption. More...
 
void add_general_help_suboption ()
 Add a smart –help suboption that takes "properties" or "operators". More...
 
const std::vector< std::string > & help_opt_vec () const
 Returns the list of strings corresponding to add_general_help_suboption() More...
 
void add_verbosity_suboption ()
 Add a –verbosity suboption. Default "standard" of "none", "quiet", "standard", "verbose", "debug" or an int 0-100. More...
 
const std::string & verbosity_str () const
 Returns the string corresponding to add_verbosity_suboption() More...
 
void add_input_suboption (bool required=true)
 Add a –input suboption. Expects a corresponding casm format to go with it. More...
 
std::string input_str () const
 Returns the path corresponding to add_input_suboption. More...
 
void add_settings_suboption (bool required=true)
 Add a –settings suboption. Expects a corresponding casm format to go with it. More...
 
const fs::path settings_path () const
 Returns the path corresponding to add_settings_suboption. More...
 
void add_output_suboption ()
 Add a –output suboption. Expects to allow "STDOUT" to print to screen. More...
 
const fs::path output_path () const
 Returns the path corresponding to add_output_suboption() More...
 
void add_gzip_suboption ()
 Add a –gzip suboption. The value will default to false unless overridden by the derived class. More...
 
bool gzip_flag () const
 Returns the value assigned for add_gzip_suboption() More...
 
void add_scelname_suboption ()
 Add a –scelname suboption. More...
 
const std::string & supercell_str () const
 Returns the name of the supercell for add_scelname_suboption() More...
 
void add_scelnames_suboption ()
 Add a –scelnames suboption. More...
 
const std::vector< std::string > & supercell_strs () const
 Returns the list of the supercells for add_scelnames_suboption() More...
 
void add_configname_suboption ()
 Add a –configname suboption. More...
 
const std::string & config_str () const
 Returns the name of the supercell for add_configname_suboption(), for when multiple=false. More...
 
void add_confignames_suboption ()
 Add a –confignames suboption. More...
 
const std::vector< std::string > & config_strs () const
 Returns the names of the supercells for add_configname_suboption(), for when multiple=false. More...
 
void add_coordtype_suboption ()
 Add a –coord suboption to specify FRAC or CART. More...
 
const std::string & coordtype_str () const
 Return the coordinate type in the form of a string. More...
 
COORD_TYPE coordtype_enum () const
 Return the coordinate type recasted as the CASM defined enum. More...
 

Protected Attributes

std::string m_tag
 name of the casm command More...
 
po::options_description m_desc
 Boost program options. All the derived classes have them, but will fill them up themselves. More...
 
po::variables_map m_vm
 Boost program options variable map. More...
 
fs::path m_selection_path
 The selection string to go with add_config_suboption. More...
 
std::vector< fs::path > m_selection_paths
 The selection string to go with add_config_suboption. More...
 
std::vector< std::string > m_help_opt_vec
 The list of strings to go with add_general_help_suboption() More...
 
std::string m_verbosity_str
 The verbosity string to go with add_config_suboption. More...
 
std::string m_input_str
 The settings path to go with add_input_suboption() More...
 
fs::path m_settings_path
 The settings path to go with add_settings_suboption() More...
 
fs::path m_output_path
 The path that goes with add_output_suboption. More...
 
bool m_gzip_flag
 The bool that goes with add_gzip_suboption. More...
 
std::string m_supercell_str
 The string of the supercell name of add_scelname_suboption() More...
 
std::vector< std::string > m_supercell_strs
 The list of supercell names of add_scelnames_suboption() More...
 
std::string m_config_str
 The name of a single configname to go with add_configname_suboption() More...
 
std::vector< std::string > m_config_strs
 The list of the supercell names of add_configname_suboption() More...
 
std::string m_coordtype_str
 The enum value in the form of a string for add_coordtype_suboption(). Only the first letter matters, but knock yourself out. More...
 

Private Member Functions

void initialize () override
 Fill in the options descriptions accordingly. More...
 

Private Attributes

std::vector< std::string > m_desc_vec
 
std::string m_method
 
int m_min_volume
 
int m_max_volume
 
bool m_all_existing
 
std::vector< std::string > m_filter_strs
 

Constructor & Destructor Documentation

CASM::Completer::EnumOption::EnumOption ( )

Definition at line 13 of file enum.cc.

Member Function Documentation

void CASM::Completer::OptionHandlerBase::add_configlist_nodefault_suboption ( )
protectedinherited

Add –config suboption (no default)

Definition at line 258 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_configlist_suboption ( const fs::path &  _default = "MASTER")
protectedinherited

Add –config suboption (defaults to MASTER)

Definition at line 238 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_configlists_nodefault_suboption ( )
protectedinherited

Add –configs suboption (no default)

Definition at line 267 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_configlists_suboption ( const fs::path &  _default = "MASTER")
protectedinherited

Add –configs suboption (defaults to MASTER)

Definition at line 248 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_configname_suboption ( )
protectedinherited

Add a –configname suboption.

Definition at line 354 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_confignames_suboption ( )
protectedinherited

Add a –confignames suboption.

Definition at line 365 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_coordtype_suboption ( )
protectedinherited

Add a –coord suboption to specify FRAC or CART.

Definition at line 377 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_general_help_suboption ( )
protectedinherited

Add a smart –help suboption that takes "properties" or "operators".

Definition at line 283 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_gzip_suboption ( )
protectedinherited

Add a –gzip suboption. The value will default to false unless overridden by the derived class.

Definition at line 332 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_help_suboption ( )
protectedinherited

Add a plain –help suboption.

Definition at line 276 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_input_suboption ( bool  required = true)
protectedinherited

Add a –input suboption. Expects a corresponding casm format to go with it.

Definition at line 311 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_output_suboption ( )
protectedinherited

Add a –output suboption. Expects to allow "STDOUT" to print to screen.

Definition at line 326 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_scelname_suboption ( )
protectedinherited

Add a –scelname suboption.

Definition at line 338 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_scelnames_suboption ( )
protectedinherited

Add a –scelnames suboption.

Definition at line 346 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_settings_suboption ( bool  required = true)
protectedinherited

Add a –settings suboption. Expects a corresponding casm format to go with it.

Definition at line 296 of file Handlers.cc.

void CASM::Completer::OptionHandlerBase::add_verbosity_suboption ( )
protectedinherited

Add a –verbosity suboption. Default "standard" of "none", "quiet", "standard", "verbose", "debug" or an int 0-100.

Definition at line 289 of file Handlers.cc.

bool CASM::Completer::EnumOption::all_existing ( ) const
inline

Definition at line 837 of file Handlers.hh.

const std::string & CASM::Completer::OptionHandlerBase::config_str ( ) const
protectedinherited

Returns the name of the supercell for add_configname_suboption(), for when multiple=false.

Definition at line 200 of file Handlers.cc.

const std::vector< std::string > & CASM::Completer::OptionHandlerBase::config_strs ( ) const
protectedinherited

Returns the names of the supercells for add_configname_suboption(), for when multiple=false.

Definition at line 204 of file Handlers.cc.

COORD_TYPE CASM::Completer::OptionHandlerBase::coordtype_enum ( ) const
protectedinherited

Return the coordinate type recasted as the CASM defined enum.

Definition at line 220 of file Handlers.cc.

const std::string & CASM::Completer::OptionHandlerBase::coordtype_str ( ) const
protectedinherited

Return the coordinate type in the form of a string.

Definition at line 216 of file Handlers.cc.

const po::options_description & CASM::Completer::OptionHandlerBase::desc ( )
inherited

Get the program options, filled with the initialized values.

Check if there are any program options in the options description. If there aren't, then this is the first time someone is asking for those values, which we set through the initialize routine. If there are values there already, just hand them back.

Definition at line 160 of file Handlers.cc.

const std::vector<std::string>& CASM::Completer::EnumOption::desc_vec ( ) const
inline

Definition at line 821 of file Handlers.hh.

const std::vector<std::string>& CASM::Completer::EnumOption::filter_strs ( ) const
inline

Definition at line 841 of file Handlers.hh.

bool CASM::Completer::OptionHandlerBase::gzip_flag ( ) const
protectedinherited

Returns the value assigned for add_gzip_suboption()

Definition at line 192 of file Handlers.cc.

const std::vector< std::string > & CASM::Completer::OptionHandlerBase::help_opt_vec ( ) const
protectedinherited

Returns the list of strings corresponding to add_general_help_suboption()

Definition at line 196 of file Handlers.cc.

void CASM::Completer::EnumOption::initialize ( )
overrideprivatevirtual

Fill in the options descriptions accordingly.

Implements CASM::Completer::OptionHandlerBase.

Definition at line 15 of file enum.cc.

std::string CASM::Completer::OptionHandlerBase::input_str ( ) const
protectedinherited

Returns the path corresponding to add_input_suboption.

Definition at line 184 of file Handlers.cc.

int CASM::Completer::EnumOption::max_volume ( ) const
inline

Definition at line 833 of file Handlers.hh.

std::string CASM::Completer::EnumOption::method ( ) const
inline

Definition at line 825 of file Handlers.hh.

int CASM::Completer::EnumOption::min_volume ( ) const
inline

Definition at line 829 of file Handlers.hh.

const fs::path CASM::Completer::OptionHandlerBase::output_path ( ) const
protectedinherited

Returns the path corresponding to add_output_suboption()

Definition at line 188 of file Handlers.cc.

const fs::path & CASM::Completer::OptionHandlerBase::selection_path ( ) const
protectedinherited

Returns the string corresponding to add_config_suboption()

Definition at line 168 of file Handlers.cc.

const std::vector< fs::path > & CASM::Completer::OptionHandlerBase::selection_paths ( ) const
protectedinherited

Returns the string corresponding to add_config_suboption()

Definition at line 172 of file Handlers.cc.

const fs::path CASM::Completer::OptionHandlerBase::settings_path ( ) const
protectedinherited

Returns the path corresponding to add_settings_suboption.

Definition at line 180 of file Handlers.cc.

const std::string & CASM::Completer::OptionHandlerBase::supercell_str ( ) const
protectedinherited

Returns the name of the supercell for add_scelname_suboption()

Definition at line 208 of file Handlers.cc.

const std::vector< std::string > & CASM::Completer::OptionHandlerBase::supercell_strs ( ) const
protectedinherited

Returns the list of the supercells for add_scelnames_suboption()

Definition at line 212 of file Handlers.cc.

const std::string & CASM::Completer::OptionHandlerBase::tag ( ) const
inherited

The desired name for the casm option (Perhaps this should get tied with CommandArg?)

Definition at line 140 of file Handlers.cc.

const std::string & CASM::Completer::OptionHandlerBase::verbosity_str ( ) const
protectedinherited

Returns the string corresponding to add_verbosity_suboption()

Definition at line 176 of file Handlers.cc.

po::variables_map & CASM::Completer::OptionHandlerBase::vm ( )
inherited

Get the variables map.

Definition at line 145 of file Handlers.cc.

const po::variables_map & CASM::Completer::OptionHandlerBase::vm ( ) const
inherited

Get the variables map.

Definition at line 150 of file Handlers.cc.

Member Data Documentation

bool CASM::Completer::EnumOption::m_all_existing
private

Definition at line 854 of file Handlers.hh.

std::string CASM::Completer::OptionHandlerBase::m_config_str
protectedinherited

The name of a single configname to go with add_configname_suboption()

Definition at line 265 of file Handlers.hh.

std::vector<std::string> CASM::Completer::OptionHandlerBase::m_config_strs
protectedinherited

The list of the supercell names of add_configname_suboption()

Definition at line 276 of file Handlers.hh.

std::string CASM::Completer::OptionHandlerBase::m_coordtype_str
protectedinherited

The enum value in the form of a string for add_coordtype_suboption(). Only the first letter matters, but knock yourself out.

Definition at line 287 of file Handlers.hh.

po::options_description CASM::Completer::OptionHandlerBase::m_desc
protectedinherited

Boost program options. All the derived classes have them, but will fill them up themselves.

Definition at line 126 of file Handlers.hh.

std::vector<std::string> CASM::Completer::EnumOption::m_desc_vec
private

Definition at line 849 of file Handlers.hh.

std::vector<std::string> CASM::Completer::EnumOption::m_filter_strs
private

Definition at line 855 of file Handlers.hh.

bool CASM::Completer::OptionHandlerBase::m_gzip_flag
protectedinherited

The bool that goes with add_gzip_suboption.

Definition at line 232 of file Handlers.hh.

std::vector<std::string> CASM::Completer::OptionHandlerBase::m_help_opt_vec
protectedinherited

The list of strings to go with add_general_help_suboption()

Definition at line 177 of file Handlers.hh.

std::string CASM::Completer::OptionHandlerBase::m_input_str
protectedinherited

The settings path to go with add_input_suboption()

Definition at line 199 of file Handlers.hh.

int CASM::Completer::EnumOption::m_max_volume
private

Definition at line 853 of file Handlers.hh.

std::string CASM::Completer::EnumOption::m_method
private

Definition at line 851 of file Handlers.hh.

int CASM::Completer::EnumOption::m_min_volume
private

Definition at line 852 of file Handlers.hh.

fs::path CASM::Completer::OptionHandlerBase::m_output_path
protectedinherited

The path that goes with add_output_suboption.

Definition at line 221 of file Handlers.hh.

fs::path CASM::Completer::OptionHandlerBase::m_selection_path
protectedinherited

The selection string to go with add_config_suboption.

Definition at line 140 of file Handlers.hh.

std::vector<fs::path> CASM::Completer::OptionHandlerBase::m_selection_paths
protectedinherited

The selection string to go with add_config_suboption.

Definition at line 151 of file Handlers.hh.

fs::path CASM::Completer::OptionHandlerBase::m_settings_path
protectedinherited

The settings path to go with add_settings_suboption()

Definition at line 210 of file Handlers.hh.

std::string CASM::Completer::OptionHandlerBase::m_supercell_str
protectedinherited

The string of the supercell name of add_scelname_suboption()

Definition at line 243 of file Handlers.hh.

std::vector<std::string> CASM::Completer::OptionHandlerBase::m_supercell_strs
protectedinherited

The list of supercell names of add_scelnames_suboption()

Definition at line 254 of file Handlers.hh.

std::string CASM::Completer::OptionHandlerBase::m_tag
protectedinherited

name of the casm command

Definition at line 123 of file Handlers.hh.

std::string CASM::Completer::OptionHandlerBase::m_verbosity_str
protectedinherited

The verbosity string to go with add_config_suboption.

Definition at line 188 of file Handlers.hh.

po::variables_map CASM::Completer::OptionHandlerBase::m_vm
protectedinherited

Boost program options variable map.

Definition at line 129 of file Handlers.hh.


The documentation for this class was generated from the following files: