From 9b653a7051bb6b9f1ad8d3f329c444741aa0fa76 Mon Sep 17 00:00:00 2001 From: Andreas Lauser Date: Thu, 5 Jan 2012 11:51:59 +0000 Subject: [PATCH] properties: remove all superfluous PTAG() invocations --- examples/tutorial_coupled.cc | 8 +++---- examples/tutorial_decoupled.cc | 10 ++++----- examples/tutorialproblem_coupled.hh | 18 +++++++-------- examples/tutorialproblem_decoupled.hh | 22 +++++++++---------- examples/tutorialspatialparameters_coupled.hh | 12 +++++----- .../tutorialspatialparameters_decoupled.hh | 10 ++++----- 6 files changed, 40 insertions(+), 40 deletions(-) diff --git a/examples/tutorial_coupled.cc b/examples/tutorial_coupled.cc index 998c340db..64ef19a5f 100644 --- a/examples/tutorial_coupled.cc +++ b/examples/tutorial_coupled.cc @@ -42,9 +42,9 @@ int main(int argc, char** argv) { try { typedef TTAG(TutorialProblemCoupled) TypeTag; /*@\label{tutorial-coupled:set-type-tag}@*/ - typedef GET_PROP_TYPE(TypeTag, PTAG(Grid)) Grid; /*@\label{tutorial-coupled:retrieve-types-begin}@*/ - typedef GET_PROP_TYPE(TypeTag, PTAG(TimeManager)) TimeManager; - typedef GET_PROP_TYPE(TypeTag, PTAG(Problem)) Problem; /*@\label{tutorial-coupled:retrieve-types-end}@*/ + typedef GET_PROP_TYPE(TypeTag, Grid) Grid; /*@\label{tutorial-coupled:retrieve-types-begin}@*/ + typedef GET_PROP_TYPE(TypeTag, TimeManager) TimeManager; + typedef GET_PROP_TYPE(TypeTag, Problem) Problem; /*@\label{tutorial-coupled:retrieve-types-end}@*/ // Initialize MPI Dune::MPIHelper::instance(argc, argv); /*@\label{tutorial-coupled:init-mpi}@*/ @@ -73,7 +73,7 @@ int main(int argc, char** argv) std::istringstream(argv[argPos++]) >> dt; /*@\label{tutorial-coupled:parse-args-end}@*/ // create the grid - Grid *gridPtr = GET_PROP(TypeTag, PTAG(Grid))::create(); /*@\label{tutorial-coupled:create-grid}@*/ + Grid *gridPtr = GET_PROP(TypeTag, Grid)::create(); /*@\label{tutorial-coupled:create-grid}@*/ // create time manager responsible for global simulation control TimeManager timeManager; diff --git a/examples/tutorial_decoupled.cc b/examples/tutorial_decoupled.cc index c0929ca4c..9f243cf9a 100644 --- a/examples/tutorial_decoupled.cc +++ b/examples/tutorial_decoupled.cc @@ -53,10 +53,10 @@ int main(int argc, char** argv) { try { typedef TTAG(TutorialProblemDecoupled) TypeTag; /*@\label{tutorial-decoupled:set-type-tag}@*/ - typedef GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; /*@\label{tutorial-decoupled:retrieve-types-begin}@*/ - typedef GET_PROP_TYPE(TypeTag, PTAG(Grid)) Grid; - typedef GET_PROP_TYPE(TypeTag, PTAG(Problem)) Problem; - typedef GET_PROP_TYPE(TypeTag, PTAG(TimeManager)) TimeManager; + typedef GET_PROP_TYPE(TypeTag, Scalar) Scalar; /*@\label{tutorial-decoupled:retrieve-types-begin}@*/ + typedef GET_PROP_TYPE(TypeTag, Grid) Grid; + typedef GET_PROP_TYPE(TypeTag, Problem) Problem; + typedef GET_PROP_TYPE(TypeTag, TimeManager) TimeManager; typedef Dune::FieldVector GlobalPosition; /*@\label{tutorial-decoupled:retrieve-types-end}@*/ // initialize MPI, finalize is done automatically on exit @@ -89,7 +89,7 @@ int main(int argc, char** argv) dt = tEnd; /*@\label{tutorial-decoupled:parse-args-end}@*/ // create the grid - Grid *gridPtr = GET_PROP(TypeTag, PTAG(Grid))::create(); /*@\label{tutorial-decoupled:create-grid}@*/ + Grid *gridPtr = GET_PROP(TypeTag, Grid)::create(); /*@\label{tutorial-decoupled:create-grid}@*/ // create time manager responsible for global simulation control TimeManager timeManager; diff --git a/examples/tutorialproblem_coupled.hh b/examples/tutorialproblem_coupled.hh index 52cd3b69f..6ff0f21e6 100644 --- a/examples/tutorialproblem_coupled.hh +++ b/examples/tutorialproblem_coupled.hh @@ -80,14 +80,14 @@ SET_PROP(TutorialProblemCoupled, Grid) /*@\label{tutorial-coupled:set-grid}@*/ // Set the wetting phase SET_PROP(TutorialProblemCoupled, WettingPhase) /*@\label{tutorial-coupled:2p-system-start}@*/ { -private: typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; +private: typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; public: typedef Dumux::LiquidPhase > type; /*@\label{tutorial-coupled:wettingPhase}@*/ }; // Set the non-wetting phase SET_PROP(TutorialProblemCoupled, NonwettingPhase) { -private: typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; +private: typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; public: typedef Dumux::LiquidPhase > type; /*@\label{tutorial-coupled:nonwettingPhase}@*/ }; /*@\label{tutorial-coupled:2p-system-end}@*/ @@ -107,8 +107,8 @@ template class TutorialProblemCoupled : public TwoPProblem /*@\label{tutorial-coupled:def-problem}@*/ { typedef TwoPProblem ParentType; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(GridView)) GridView; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, GridView) GridView; // Grid dimension enum { dim = GridView::dimension }; @@ -120,11 +120,11 @@ class TutorialProblemCoupled : public TwoPProblem /*@\label{tutorial-co typedef Dune::FieldVector GlobalPosition; // Dumux specific types - typedef typename GET_PROP_TYPE(TypeTag, PTAG(TimeManager)) TimeManager; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(TwoPIndices)) Indices; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(PrimaryVariables)) PrimaryVariables; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(BoundaryTypes)) BoundaryTypes; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(FVElementGeometry)) FVElementGeometry; + typedef typename GET_PROP_TYPE(TypeTag, TimeManager) TimeManager; + typedef typename GET_PROP_TYPE(TypeTag, TwoPIndices) Indices; + typedef typename GET_PROP_TYPE(TypeTag, PrimaryVariables) PrimaryVariables; + typedef typename GET_PROP_TYPE(TypeTag, BoundaryTypes) BoundaryTypes; + typedef typename GET_PROP_TYPE(TypeTag, FVElementGeometry) FVElementGeometry; public: TutorialProblemCoupled(TimeManager &timeManager, diff --git a/examples/tutorialproblem_decoupled.hh b/examples/tutorialproblem_decoupled.hh index c46e48c17..24690fc95 100644 --- a/examples/tutorialproblem_decoupled.hh +++ b/examples/tutorialproblem_decoupled.hh @@ -89,7 +89,7 @@ SET_PROP(TutorialProblemDecoupled, Grid) /*@\label{tutorial-decoupled:grid-begin SET_PROP(TutorialProblemDecoupled, WettingPhase) /*@\label{tutorial-decoupled:2p-system-start}@*/ { private: - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; public: typedef Dumux::LiquidPhase > type; /*@\label{tutorial-decoupled:wettingPhase}@*/ }; @@ -98,7 +98,7 @@ public: SET_PROP(TutorialProblemDecoupled, NonwettingPhase) { private: - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; public: typedef Dumux::LiquidPhase > type; /*@\label{tutorial-decoupled:nonwettingPhase}@*/ }; /*@\label{tutorial-decoupled:2p-system-end}@*/ @@ -116,7 +116,7 @@ SET_PROP(TutorialProblemDecoupled, PressureModel) /*@\label{tutorial-decoupled:P // model-specific settings SET_INT_PROP(TutorialProblemDecoupled, VelocityFormulation, - GET_PROP_TYPE(TypeTag, PTAG(Indices))::velocityW); /*@\label{tutorial-decoupled:velocityFormulation}@*/ + GET_PROP_TYPE(TypeTag, Indices)::velocityW); /*@\label{tutorial-decoupled:velocityFormulation}@*/ SET_TYPE_PROP(TutorialProblemDecoupled, DiffusivePart, @@ -135,15 +135,15 @@ template class TutorialProblemDecoupled: public IMPESProblem2P /*@\label{tutorial-decoupled:def-problem}@*/ { typedef IMPESProblem2P ParentType; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(GridView)) GridView; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(TimeManager)) TimeManager; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Indices)) Indices; + typedef typename GET_PROP_TYPE(TypeTag, GridView) GridView; + typedef typename GET_PROP_TYPE(TypeTag, TimeManager) TimeManager; + typedef typename GET_PROP_TYPE(TypeTag, Indices) Indices; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(FluidSystem)) FluidSystem; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(FluidState)) FluidState; + typedef typename GET_PROP_TYPE(TypeTag, FluidSystem) FluidSystem; + typedef typename GET_PROP_TYPE(TypeTag, FluidState) FluidState; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(BoundaryTypes)) BoundaryTypes; - typedef typename GET_PROP(TypeTag, PTAG(SolutionTypes)) SolutionTypes; + typedef typename GET_PROP_TYPE(TypeTag, BoundaryTypes) BoundaryTypes; + typedef typename GET_PROP(TypeTag, SolutionTypes) SolutionTypes; typedef typename SolutionTypes::PrimaryVariables PrimaryVariables; enum @@ -161,7 +161,7 @@ class TutorialProblemDecoupled: public IMPESProblem2P /*@\label{tutoria satEqIdx = Indices::satEqIdx }; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; typedef typename GridView::Traits::template Codim<0>::Entity Element; typedef typename GridView::Intersection Intersection; diff --git a/examples/tutorialspatialparameters_coupled.hh b/examples/tutorialspatialparameters_coupled.hh index bb76d9996..f98943063 100644 --- a/examples/tutorialspatialparameters_coupled.hh +++ b/examples/tutorialspatialparameters_coupled.hh @@ -55,7 +55,7 @@ SET_PROP(TutorialSpatialParametersCoupled, MaterialLaw) { private: // material law typedefs - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; // select material law to be used typedef RegularizedBrooksCorey RawMaterialLaw; /*@\label{tutorial-coupled:rawlaw}@*/ public: @@ -74,9 +74,9 @@ template class TutorialSpatialParametersCoupled: public BoxSpatialParameters /*@\label{tutorial-coupled:tutorialSpatialParameters}@*/ { // Get informations for current implementation via property system - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Grid)) Grid; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(GridView)) GridView; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, Grid) Grid; + typedef typename GET_PROP_TYPE(TypeTag, GridView) GridView; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; enum { dim = Grid::dimension, @@ -85,12 +85,12 @@ class TutorialSpatialParametersCoupled: public BoxSpatialParameters /*@ typedef Dune::FieldVector GlobalPosition; // Get object types for function arguments - typedef typename GET_PROP_TYPE(TypeTag, PTAG(FVElementGeometry)) FVElementGeometry; + typedef typename GET_PROP_TYPE(TypeTag, FVElementGeometry) FVElementGeometry; typedef typename Grid::Traits::template Codim<0>::Entity Element; public: // get material law from property system - typedef typename GET_PROP_TYPE(TypeTag, PTAG(MaterialLaw)) MaterialLaw; + typedef typename GET_PROP_TYPE(TypeTag, MaterialLaw) MaterialLaw; // determine appropriate parameters depening on selected materialLaw typedef typename MaterialLaw::Params MaterialLawParams; /*@\label{tutorial-coupled:matLawObjectType}@*/ diff --git a/examples/tutorialspatialparameters_decoupled.hh b/examples/tutorialspatialparameters_decoupled.hh index 63841d086..28530dfb3 100644 --- a/examples/tutorialspatialparameters_decoupled.hh +++ b/examples/tutorialspatialparameters_decoupled.hh @@ -53,7 +53,7 @@ SET_PROP(TutorialSpatialParametersDecoupled, MaterialLaw) { private: // material law typedefs - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; typedef RegularizedBrooksCorey RawMaterialLaw; public: typedef EffToAbsLaw type; @@ -66,9 +66,9 @@ template class TutorialSpatialParametersDecoupled: public FVSpatialParameters { typedef FVSpatialParameters ParentType; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Grid)) Grid; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(GridView)) GridView; - typedef typename GET_PROP_TYPE(TypeTag, PTAG(Scalar)) Scalar; + typedef typename GET_PROP_TYPE(TypeTag, Grid) Grid; + typedef typename GET_PROP_TYPE(TypeTag, GridView) GridView; + typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar; typedef typename Grid::ctype CoordScalar; enum @@ -80,7 +80,7 @@ class TutorialSpatialParametersDecoupled: public FVSpatialParameters typedef Dune::FieldMatrix FieldMatrix; public: - typedef typename GET_PROP_TYPE(TypeTag, PTAG(MaterialLaw)) MaterialLaw; + typedef typename GET_PROP_TYPE(TypeTag, MaterialLaw) MaterialLaw; typedef typename MaterialLaw::Params MaterialLawParams; //! Intrinsic permeability tensor K \f$[m^2]\f$ depending