From ab4c6921db2c281cea4ea96dccbb58c519d3db67 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Christoph=20Gr=C3=BCninger?=
 <christoph.grueninger@iws.uni-stuttgart.de>
Date: Wed, 23 Mar 2016 07:36:50 +0100
Subject: [PATCH] [cleanup] Remove deprecated functions in common and material

---
 dumux/common/boundarytypes.hh                 | 136 ------------------
 dumux/common/intersectionmapper.hh            |  31 ----
 .../electrochemistry/electrochemistry.hh      |  13 --
 dumux/material/components/nacl.hh             |   9 --
 4 files changed, 189 deletions(-)

diff --git a/dumux/common/boundarytypes.hh b/dumux/common/boundarytypes.hh
index 94e3905503..6c14e3e253 100644
--- a/dumux/common/boundarytypes.hh
+++ b/dumux/common/boundarytypes.hh
@@ -23,8 +23,6 @@
 #ifndef BOUNDARY_TYPES_HH
 #define BOUNDARY_TYPES_HH
 
-#include <dune/common/deprecated.hh>
-
 #include <dumux/common/valgrind.hh>
 
 namespace Dumux
@@ -163,42 +161,6 @@ public:
         }
     }
 
-    /*!
-     * \brief Set all boundary conditions to coupling inflow.
-     */
-    DUNE_DEPRECATED_MSG("setAllCouplingInflow() is deprecated. Use setAllCouplingNeumann() instead.")
-    void setAllCouplingInflow()
-    {
-        for (int eqIdx = 0; eqIdx < numEq; ++eqIdx)
-        {
-            setCouplingNeumann(eqIdx);
-        }
-    }
-
-    /*!
-     * \brief Set all boundary conditions to coupling outflow.
-     */
-    DUNE_DEPRECATED_MSG("setAllCouplingOutflow() is deprecated. Use setAllCouplingDirichlet() instead.")
-    void setAllCouplingOutflow()
-    {
-        for (int eqIdx = 0; eqIdx < numEq; ++eqIdx)
-        {
-            setCouplingDirichlet(eqIdx);
-        }
-    }
-
-    /*!
-     * \brief Set all boundary conditions to mortar coupling.
-     */
-    DUNE_DEPRECATED_MSG("setAllMortarCoupling() is deprecated. Use setAllCouplingMortar() instead.")
-    void setAllMortarCoupling()
-    {
-        for (int eqIdx = 0; eqIdx < numEq; ++eqIdx)
-        {
-            setCouplingMortar(eqIdx);
-        }
-    }
-
     /*!
      * \brief Set a Neumann boundary condition for a single a single
      *        equation.
@@ -291,33 +253,6 @@ public:
         Valgrind::SetDefined(boundaryInfo_[eqIdx]);
     }
 
-    /*!
-     * \brief Set a boundary condition for a single equation to coupling inflow.
-     */
-    DUNE_DEPRECATED_MSG("setCouplingInflow() is deprecated. Use setCouplingNeumann() instead.")
-    void setCouplingInflow(int eqIdx)
-    {
-        setCouplingNeumann(eqIdx);
-    }
-
-    /*!
-     * \brief Set a boundary condition for a single equation to coupling outflow.
-     */
-    DUNE_DEPRECATED_MSG("setCouplingOutflow() is deprecated. Use setCouplingDirichlet() instead.")
-    void setCouplingOutflow(int eqIdx)
-    {
-        setCouplingDirichlet(eqIdx);
-    }
-
-    /*!
-     * \brief Set a boundary condition for a single equation to mortar coupling.
-     */
-    DUNE_DEPRECATED_MSG("setMortarCoupling() is deprecated. Use setCouplingMortar() instead.")
-    void setMortarCoupling(int eqIdx)
-    {
-        setCouplingMortar(eqIdx);
-    }
-
     /*!
      * \brief Set a Dirichlet boundary condition for a single primary
      *        variable.
@@ -396,77 +331,6 @@ public:
         return false;
     }
 
-    /*!
-     * \brief Returns true if an equation is used to specify an
-     *        inflow coupling condition.
-     *
-     * \param eqIdx The index of the equation
-     */
-    DUNE_DEPRECATED_MSG("isCouplingInflow() is deprecated. Use isCouplingNeumann() instead.")
-    bool isCouplingInflow(unsigned eqIdx) const
-    { return boundaryInfo_[eqIdx].isCouplingNeumann; }
-
-    /*!
-     * \brief Returns true if some equation is used to specify an
-     *        inflow coupling condition.
-     */
-    DUNE_DEPRECATED_MSG("hasCouplingInflow() is deprecated. Use hasCouplingNeumann() instead.")
-    bool hasCouplingInflow() const
-    {
-        for (int i = 0; i < numEq; ++i)
-            if (boundaryInfo_[i].isCouplingNeumann)
-                return true;
-        return false;
-    }
-
-    /*!
-     * \brief Returns true if an equation is used to specify an
-     *        outflow coupling condition.
-     *
-     * \param eqIdx The index of the equation
-     */
-    DUNE_DEPRECATED_MSG("isCouplingOutflow() is deprecated. Use isCouplingDirichlet() instead.")
-    bool isCouplingOutflow(unsigned eqIdx) const
-    { return boundaryInfo_[eqIdx].isCouplingDirichlet; }
-
-    /*!
-     * \brief Returns true if some equation is used to specify an
-     *        outflow coupling condition.
-     */
-    DUNE_DEPRECATED_MSG("hasCouplingOutflow() is deprecated. Use hasCouplingDirichlet() instead.")
-    bool hasCouplingOutflow() const
-    {
-        for (int i = 0; i < numEq; ++i)
-            if (boundaryInfo_[i].isCouplingDirichlet)
-                return true;
-        return false;
-    }
-
-    /*!
-     * \brief Returns true if an equation is used to specify a
-     *        mortar coupling condition.
-     *
-     * \param eqIdx The index of the equation
-     */
-    DUNE_DEPRECATED_MSG("isMortarCoupling() is deprecated. Use isCouplingMortar() instead.")
-    bool isMortarCoupling(unsigned eqIdx) const
-    {
-        return boundaryInfo_[eqIdx].isCouplingMortar;
-    }
-
-    /*!
-     * \brief Returns true if some equation is used to specify a
-     *        mortar coupling condition.
-     */
-    DUNE_DEPRECATED_MSG("hasMortarCoupling() is deprecated. Use hasCouplingMortar() instead.")
-    bool hasMortarCoupling() const
-    {
-        for (int i = 0; i < numEq; ++i)
-            if (boundaryInfo_[i].isCouplingMortar)
-                return true;
-        return false;
-    }
-
     /*!
      * \brief Returns true if an equation is used to specify an
      *        Dirichlet coupling condition.
diff --git a/dumux/common/intersectionmapper.hh b/dumux/common/intersectionmapper.hh
index 24236c4266..dcee8ab505 100644
--- a/dumux/common/intersectionmapper.hh
+++ b/dumux/common/intersectionmapper.hh
@@ -21,7 +21,6 @@
 #include <vector>
 #include <unordered_map>
 
-#include <dune/common/deprecated.hh>
 #include <dune/grid/common/mcmgmapper.hh>
 #include <dune/grid/common/rangegenerators.hh>
 
@@ -70,12 +69,6 @@ public:
         return elementMapper_;
     }
 
-    DUNE_DEPRECATED_MSG("Map is deprecated in 2.9, use index instead.")
-    int map(const Element& element) const
-    {
-        return elementMapper_.index(element);
-    }
-
     /*!
      * \brief Map element to array index.
      *
@@ -87,12 +80,6 @@ public:
         return elementMapper_.index(element);
     }
 
-    DUNE_DEPRECATED_MSG("Map is deprecated in 2.9, use subIndex instead.")
-    int map(int elemIdx, int fIdx)
-    {
-        return intersectionMapGlobal_[elemIdx][fIdx];
-    }
-
     /*!
      * \brief Map interface fIdx'th interface of element index to array index.
      *
@@ -105,12 +92,6 @@ public:
         return intersectionMapGlobal_[elemIdx][fIdx];
     }
 
-    DUNE_DEPRECATED_MSG("Map is deprecated in 2.9, use subIndex instead.")
-    int map(int elemIdx, int fIdx) const
-    {
-        return (intersectionMapGlobal_[elemIdx].find(fIdx))->second;//use find() for const function!
-    }
-
     /*!
      * \brief Map interface fIdx'th interface of element index to array index.
      *
@@ -123,12 +104,6 @@ public:
         return (intersectionMapGlobal_[elemIdx].find(fIdx))->second;//use find() for const function!
     }
 
-    DUNE_DEPRECATED_MSG("Map is deprecated in 2.9, use subIndex instead.")
-    int map(const Element& element, int fIdx)
-    {
-        return intersectionMapGlobal_[index(element)][fIdx];
-    }
-
     /*!
      * \brief Map interface fIdx'th interface of element to array index.
      *
@@ -141,12 +116,6 @@ public:
         return intersectionMapGlobal_[index(element)][fIdx];
     }
 
-    DUNE_DEPRECATED_MSG("Map is deprecated in 2.9, use subIndex instead.")
-    int map(const Element& element, int fIdx) const
-    {
-        return intersectionMapGlobal_[index(element)].find(fIdx)->second;//use find() for const function!
-    }
-
     int subIndex(const Element& element, int fIdx) const
     {
         return intersectionMapGlobal_[index(element)].find(fIdx)->second;//use find() for const function!
diff --git a/dumux/material/chemistry/electrochemistry/electrochemistry.hh b/dumux/material/chemistry/electrochemistry/electrochemistry.hh
index 0c9da48a0e..3fde11b2a5 100644
--- a/dumux/material/chemistry/electrochemistry/electrochemistry.hh
+++ b/dumux/material/chemistry/electrochemistry/electrochemistry.hh
@@ -26,7 +26,6 @@
 
 #include <cmath>
 
-#include <dune/common/deprecated.hh>
 #include <dumux/common/basicproperties.hh>
 #include <dumux/common/exceptions.hh>
 #include <dumux/material/constants.hh>
@@ -137,13 +136,6 @@ public:
         values[contiO2EqIdx]  = -currentDensity/(4*Constant::F);                 //O2-equation
     }
 
-    DUNE_DEPRECATED_MSG("First compute the currentDensity with calculateCurrentDensity(const VolumeVariables&) and then use the method reactionSource(PrimaryVariables&, Scalar) instead")
-    static void reactionSource(PrimaryVariables &values,
-                               const VolumeVariables &volVars)
-    {
-        reactionSource(values, calculateCurrentDensity(volVars));
-    }
-
     /*!
     * \brief Newton solver for calculation of the current density.
     * \returns The current density in A/m^2
@@ -210,11 +202,6 @@ public:
         return currentDensity*10000;
     }
 
-protected:
-    DUNE_DEPRECATED_MSG("This is now a public member function (the name lost the underscore postfix.)")
-    static Scalar calculateCurrentDensity_(const VolumeVariables &volVars)
-    { calculateCurrentDensity(volVars); }
-
 private:
 
     /*!
diff --git a/dumux/material/components/nacl.hh b/dumux/material/components/nacl.hh
index aa53927605..9717fbfbe5 100644
--- a/dumux/material/components/nacl.hh
+++ b/dumux/material/components/nacl.hh
@@ -67,15 +67,6 @@ public:
         return 2e-9;
     }
 
-    /*!
-     * \brief The mass density \f$\mathrm{[kg/m^3]}\f$ of NaCl.
-     */
-    DUNE_DEPRECATED_MSG("Density() is deprecated. Use density() instead.")
-    static Scalar Density()
-    {
-        return density();
-    }
-
     /*!
      * \brief The mass density \f$\mathrm{[kg/m^3]}\f$ of NaCl.
      */
-- 
GitLab