Skip to content

Feature/parameter

Tobias Malkmus requested to merge feature/parameter into master

Currently, parameters are either fetched from the singleton Parameter class or provided by the user through a LocalParameters object (if supported). As a drawback of the singleton class, the user cannot exchange parameters in the code (this behavior is, of course, intended). On the other hand, it is quite cumbersome to write a LocalParameters class for every object you might want to create.

This branch implements a hybrid between the two approaches: It allows the user to exchange the parameter container (by default, the singleton is used). To this end, the parameter class is split into three parts:

  • a singleton object (provides a singleton container and forwards all methods to it),
  • a default container implementation (which the user can create, if desired),
  • a parameter reader implementing all "get*" methods based on a single function object. Both, the parameter container and the parameter reader are copy-constructible. The parameter reader is a slim object, internally only holding a reference to the container.

From a user perspective, this change only add flexibility. Implementors would be requested to support parameter readers instead of requiring the singleton class whereever possible.

Files to edit:

  • ./dune/fem/io/file/dataoutput.hh
  • ./dune/fem/io/file/datawriter.hh
  • ./dune/fem/io/file/iointerface.hh
  • ./dune/fem/io/file/persistencemanager.hh
  • ./dune/fem/io/file/vtkio.hh
  • ./dune/fem/misc/gridsolution.hh
  • ./dune/fem/misc/threads/domainthreaditerator.hh
  • ./dune/fem/misc/threads/threaditerator.hh
  • ./dune/fem/operator/common/automaticdifferenceoperator.hh
  • ./dune/fem/operator/matrix/istlmatrix.hh
  • ./dune/fem/solver/cginverseoperator.hh
  • ./dune/fem/solver/istlinverseoperators.hh
  • ./dune/fem/solver/istlsolver.hh
  • ./dune/fem/solver/ldlsolver.hh
  • ./dune/fem/solver/newtoninverseoperator.hh
  • ./dune/fem/solver/odesolver.hh
  • ./dune/fem/solver/oemsolver/oemsolver.hh
  • ./dune/fem/solver/parameter.hh
  • ./dune/fem/solver/pardg.hh
  • ./dune/fem/solver/pardginverseoperators.hh
  • ./dune/fem/solver/petscsolver.hh
  • ./dune/fem/solver/rungekutta/basicrow.hh
  • ./dune/fem/solver/rungekutta/timestepcontrol.hh
  • ./dune/fem/solver/spqrsolver.hh
  • ./dune/fem/solver/timeprovider.hh
  • ./dune/fem/solver/umfpacksolver.hh
  • ./dune/fem/space/basisfunctionset/codegen.hh
  • ./dune/fem/space/common/adaptmanager.hh
  • ./dune/fem/space/common/loadbalancer.hh

Merge request reports