#include <dirichlet_bc_factory_abstract.h>
GRINS::DirichletBCFactoryAbstract::DirichletBCFactoryAbstract |
( |
const std::string & |
bc_type_name | ) |
|
|
inline |
GRINS::DirichletBCFactoryAbstract::~DirichletBCFactoryAbstract |
( |
| ) |
|
|
inline |
void GRINS::DirichletBCFactoryAbstract::check_for_vars |
( |
const GetPot & |
input, |
|
|
const std::string & |
section, |
|
|
const std::vector< std::string > & |
var_names, |
|
|
std::set< std::string > * |
vars_found = NULL |
|
) |
| |
|
protected |
Helper function.
This will search the given section to make sure at least one of the var names as been set. An error will be thrown if no vars were found to be set. Those vars that have been set in the input file are returned in the vars_found variable, if vars_found is not NULL.
Definition at line 58 of file dirichlet_bc_factory_abstract.C.
Referenced by GRINS::ConstantFunctionDirichletBCFactory::build_func().
65 bool found_var =
false;
67 for( std::vector<std::string>::const_iterator name = var_names.begin();
68 name < var_names.end(); ++name )
70 if( input.have_variable( section+
"/"+(*name) ) )
75 vars_found->insert( (*name) );
83 std::string err_msg =
"ERROR: Could find any active variable assigned a Dirichlet boundary value\n";
84 err_msg +=
" in section "+section+
". Active variables are:\n";
86 for( std::vector<std::string>::const_iterator name = var_names.begin();
87 name < var_names.end(); ++name )
88 err_msg +=
" "+(*name)+
"\n";
90 libmesh_error_msg(err_msg);
94 libmesh_assert(!vars_found->empty());
The documentation for this class was generated from the following files: