Skip to content
Snippets Groups Projects
Commit 39ceb452 authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

Do not inherit constructors

parent 8f72fa94
No related branches found
No related tags found
No related merge requests found
...@@ -45,11 +45,14 @@ template <class VectorType, class MatrixType, class FunctionType, int dim> ...@@ -45,11 +45,14 @@ template <class VectorType, class MatrixType, class FunctionType, int dim>
class ImplicitEuler class ImplicitEuler
: public TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim> { : public TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim> {
public: public:
// Work around the fact that nobody implements constructor inheritance ImplicitEuler(VectorType const &_ell, MatrixType const &_A,
template <class... Args> VectorType const &_u_old, VectorType const *_u_old_old_ptr,
ImplicitEuler(Args &&... args) Dune::BitSetVector<dim> const &_dirichletNodes,
: TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim>(args...) { FunctionType const &_dirichletFunction, double _time,
} double _tau)
: TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim>(
_ell, _A, _u_old, _u_old_old_ptr, _dirichletNodes,
_dirichletFunction, _time, _tau) {}
void virtual setup(VectorType &problem_rhs, VectorType &problem_iterate, void virtual setup(VectorType &problem_rhs, VectorType &problem_iterate,
MatrixType &problem_A) const { MatrixType &problem_A) const {
...@@ -95,11 +98,14 @@ template <class VectorType, class MatrixType, class FunctionType, int dim> ...@@ -95,11 +98,14 @@ template <class VectorType, class MatrixType, class FunctionType, int dim>
class ImplicitTwoStep class ImplicitTwoStep
: public TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim> { : public TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim> {
public: public:
// Work around the fact that nobody implements constructor inheritance ImplicitTwoStep(VectorType const &_ell, MatrixType const &_A,
template <class... Args> VectorType const &_u_old, VectorType const *_u_old_old_ptr,
ImplicitTwoStep(Args &&... args) Dune::BitSetVector<dim> const &_dirichletNodes,
: TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim>(args...) { FunctionType const &_dirichletFunction, double _time,
} double _tau)
: TimeSteppingScheme<VectorType, MatrixType, FunctionType, dim>(
_ell, _A, _u_old, _u_old_old_ptr, _dirichletNodes,
_dirichletFunction, _time, _tau) {}
void virtual setup(VectorType &problem_rhs, VectorType &problem_iterate, void virtual setup(VectorType &problem_rhs, VectorType &problem_iterate,
MatrixType &problem_A) const { MatrixType &problem_A) const {
......
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