4 #include <boost/algorithm/string.hpp> 23 modes.push_back(map_entry.first);
27 modes.push_back(
"initial");
36 string error_string =
"\033[0;31mError: \033[0;35m'" +
37 run_mode +
"'" +
"\033[0m" +
" is not a valid run mode." +
38 "\nAccepted run mode(s):\n";
40 error_string +=
"\t* " + mode +
'\n';
41 throw std::runtime_error(error_string);
47 throw std::runtime_error(
string(
"\033[0;31m") +
"Error: " +
string(
"\033[0m") +
"Only run mode " +
48 string(
"\033[0;35m") +
"'Initial'" +
string(
"\033[0m") +
" is allowed when running without HDF5.\n");
Time Dependent Person DataType.
static RunMode getRunMode(string run_mode)
static map< string, RunMode > g_name_run_mode
static vector< string > getAcceptedModes()