Skip to content
Snippets Groups Projects
Commit 252ad5fc authored by Dr. Felix Tobias Schindler's avatar Dr. Felix Tobias Schindler Committed by Tobias Leibner
Browse files

[P|integrand.linear-advection] update

parent a4a035eb
No related branches found
No related tags found
1 merge request!10Draft: consolidate refactoring work
...@@ -57,18 +57,25 @@ public: ...@@ -57,18 +57,25 @@ public:
const auto ClassName = XT::Common::to_camel_case(class_name); const auto ClassName = XT::Common::to_camel_case(class_name);
bound_type c(m, ClassName.c_str(), ClassName.c_str()); bound_type c(m, ClassName.c_str(), ClassName.c_str());
c.def(py::init([](const XT::Functions::GridFunctionInterface<E, d, 1, F>& direction, c.def(py::init([](const XT::Functions::GridFunctionInterface<E, d, 1, F>& direction,
const std::string& logging_prefix) { return new type(direction, logging_prefix); }), const bool advection_in_divergence_form,
const std::string& logging_prefix) {
return new type(direction, advection_in_divergence_form, logging_prefix);
}),
"direction"_a, "direction"_a,
"advection_in_divergence_form"_a = true,
"logging_prefix"_a = ""); "logging_prefix"_a = "");
// factories // factories
const auto FactoryName = XT::Common::to_camel_case(class_id); const auto FactoryName = XT::Common::to_camel_case(class_id);
m.def( m.def(
FactoryName.c_str(), FactoryName.c_str(),
[](const XT::Functions::GridFunctionInterface<E, d, 1, F>& direction, const std::string& logging_prefix) { [](const XT::Functions::GridFunctionInterface<E, d, 1, F>& direction,
return new type(direction, logging_prefix); const bool advection_in_divergence_form,
const std::string& logging_prefix) {
return new type(direction, advection_in_divergence_form, logging_prefix);
}, },
"direction"_a, "direction"_a,
"advection_in_divergence_form"_a = true,
"logging_prefix"_a = ""); "logging_prefix"_a = "");
return c; return c;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment