|
Reference documentation for deal.II version 9.2.0
|
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\)
\(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\)
\(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\)
\(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Go to the documentation of this file.
20 #include <boost/core/demangle.hpp>
33 : acceptor_id(class_list.size())
37 this, boost::core::demangle(
typeid(*this).name()).c_str());
51 boost::core::demangle(
typeid(*this).name()));
57 const std::string & filename,
58 const std::string & output_filename,
64 if (!filename.empty())
70 catch (const ::PathSearch::ExcFileNotFound &)
74 ExcMessage(
"You specified <" + filename +
"> as input " +
75 "parameter file, but it does not exist. " +
76 "We created it for you."));
80 if (!output_filename.empty())
124 if (instance !=
nullptr)
126 instance->enter_my_subsection(
prm);
127 instance->parse_parameters(
prm);
128 instance->parse_parameters_call_back();
129 instance->leave_my_subsection(
prm);
137 if (instance !=
nullptr)
139 instance->enter_my_subsection(
prm);
140 instance->declare_parameters(
prm);
141 instance->declare_parameters_call_back();
142 instance->leave_my_subsection(
prm);
147 std::vector<std::string>
152 const bool is_absolute = (my_section_name.front() ==
sep);
154 std::vector<std::string> sections =
161 sections.erase(sections.begin());
171 bool has_trailing =
class_list[i]->get_section_name().back() ==
sep;
172 auto previous_path =
class_list[i]->get_section_path();
175 if ((previous_path.size() > 0) && has_trailing ==
false)
176 previous_path.resize(previous_path.size() - 1);
178 sections.insert(sections.begin(),
179 previous_path.begin(),
180 previous_path.end());
193 for (
const auto &
sec : sections)
204 for (
unsigned int i = 0; i < sections.size(); ++i)
static void parse_all_parameters(ParameterHandler &prm=ParameterAcceptor::prm)
virtual void parse_parameters(ParameterHandler &prm)
static ::ExceptionBase & ExcIO()
void enter_my_subsection(ParameterHandler &prm)
static std::vector< SmartPointer< ParameterAcceptor > > class_list
static void declare_all_parameters(ParameterHandler &prm=ParameterAcceptor::prm)
ParameterAcceptor(const std::string §ion_name="")
static void initialize(const std::string &filename="", const std::string &output_filename="", const ParameterHandler::OutputStyle output_style_for_output_filename=ParameterHandler::Short, ParameterHandler &prm=ParameterAcceptor::prm, const ParameterHandler::OutputStyle output_style_for_filename=ParameterHandler::DefaultStyle)
static ::ExceptionBase & ExcMessage(std::string arg1)
#define DEAL_II_NAMESPACE_OPEN
virtual ~ParameterAcceptor() override
std::ostream & print_parameters(std::ostream &out, const OutputStyle style) const
std::string get_section_name() const
std::vector< std::string > get_section_path() const
static ParameterHandler prm
virtual void declare_parameters(ParameterHandler &prm)
static ::ExceptionBase & ExcInternalError()
std::vector< std::string > split_string_list(const std::string &s, const std::string &delimiter=",")
#define Assert(cond, exc)
const std::string section_name
void enter_subsection(const std::string &subsection)
#define DEAL_II_NAMESPACE_CLOSE
#define AssertThrow(cond, exc)
void leave_my_subsection(ParameterHandler &prm)
virtual void parse_input(std::istream &input, const std::string &filename="input file", const std::string &last_line="", const bool skip_undefined=false)
Expression sec(const Expression &x)
const unsigned int acceptor_id