Commit 14246401 authored by Kilian Weishaupt's avatar Kilian Weishaupt
Browse files

[sequential] Replace property system macros

parent 6dae509d
......@@ -47,7 +47,7 @@ template<class TypeTag>
class CellData1P
{
private:
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using FluxData = FluxData1P<TypeTag>;
private:
......
......@@ -57,18 +57,18 @@ template<class TypeTag> class FVPressure1P: public FVPressure<TypeTag>
{
using ParentType = FVPressure<TypeTag>;
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
using GridView = GetPropType<TypeTag, Properties::GridView>;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using Problem = GetPropType<TypeTag, Properties::Problem>;
using Indices = typename GET_PROP_TYPE(TypeTag, ModelTraits)::Indices;
using Indices = typename GetPropType<TypeTag, Properties::ModelTraits>::Indices;
using FluidSystem = typename GET_PROP_TYPE(TypeTag, FluidSystem);
using FluidSystem = GetPropType<TypeTag, Properties::FluidSystem>;
using BoundaryTypes = typename GET_PROP_TYPE(TypeTag, BoundaryTypes);
using SolutionTypes = typename GET_PROP(TypeTag, SolutionTypes);
using BoundaryTypes = GetPropType<TypeTag, Properties::BoundaryTypes>;
using SolutionTypes = GetProp<TypeTag, Properties::SolutionTypes>;
using PrimaryVariables = typename SolutionTypes::PrimaryVariables;
using CellData = typename GET_PROP_TYPE(TypeTag, CellData);
using CellData = GetPropType<TypeTag, Properties::CellData>;
using ScalarSolutionType = typename SolutionTypes::ScalarSolution;
enum
......
......@@ -26,7 +26,7 @@
#define DUMUX_FVPRESSUREPORPERTIES1P_SEQUENTIAL_HH
//Dumux-includes
#include <dumux/common/properties/propertysystemmacros.hh>
#include <dumux/common/properties.hh>
#include <dumux/porousmediumflow/1p/sequential/diffusion/properties.hh>
namespace Dumux {
......@@ -45,7 +45,10 @@ namespace Properties {
//////////////////////////////////////////////////////////////////
//! The type tag for the one-phase problems using a standard finite volume model
NEW_TYPE_TAG(FVPressureOneP, INHERITS_FROM(PressureOneP));
// Create new type tags
namespace TTag {
struct FVPressureOneP { using InheritsFrom = std::tuple<PressureOneP>; };
} // end namespace TTag
//////////////////////////////////////////////////////////////////
// Property tags
......@@ -63,11 +66,14 @@ namespace Properties {
// Properties
//////////////////////////////////////////////////////////////////
//! Set velocity reconstruction implementation standard cell centered finite volume schemes as default
SET_TYPE_PROP( FVPressureOneP, Velocity, FVVelocity1P<TypeTag> );
template<class TypeTag>
struct Velocity<TypeTag, TTag:: FVPressureOneP> { using type = FVVelocity1P<TypeTag> ; };
//! Set finite volume implementation of the one-phase pressure equation as default pressure model
SET_TYPE_PROP(FVPressureOneP, PressureModel, FVPressure1P<TypeTag>);
template<class TypeTag>
struct PressureModel<TypeTag, TTag::FVPressureOneP> { using type = FVPressure1P<TypeTag>; };
//! Allow assembling algorithm for the pressure matrix to assemble only from one side of a cell-cell interface
SET_BOOL_PROP(FVPressureOneP, VisitFacesOnlyOnce, true);
template<class TypeTag>
struct VisitFacesOnlyOnce<TypeTag, TTag::FVPressureOneP> { static constexpr bool value = true; };
// \}
} // end namespace Properties
} // end namespace Dumux
......
......@@ -56,7 +56,7 @@ namespace Dumux {
template<class TypeTag> class FVPressureVelocity1P: public FVPressure1P<TypeTag>
{
using ParentType = FVPressure1P<TypeTag>;
using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
using Problem = GetPropType<TypeTag, Properties::Problem>;
public:
/*!
* \brief Initializes the pressure model
......@@ -105,7 +105,7 @@ public:
{}
private:
FVVelocity<TypeTag, typename GET_PROP_TYPE(TypeTag, Velocity) > velocity_;
FVVelocity<TypeTag, GetPropType<TypeTag, Properties::Velocity> > velocity_;
};
} // end namespace Dumux
......
......@@ -47,18 +47,18 @@ namespace Dumux {
template<class TypeTag>
class FVVelocity1P
{
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
using GridView = GetPropType<TypeTag, Properties::GridView>;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using Problem = GetPropType<TypeTag, Properties::Problem>;
using Indices = typename GET_PROP_TYPE(TypeTag, ModelTraits)::Indices;
using Indices = typename GetPropType<TypeTag, Properties::ModelTraits>::Indices;
using FluidSystem = typename GET_PROP_TYPE(TypeTag, FluidSystem);
using FluidSystem = GetPropType<TypeTag, Properties::FluidSystem>;
using BoundaryTypes = typename GET_PROP_TYPE(TypeTag, BoundaryTypes);
using SolutionTypes = typename GET_PROP(TypeTag, SolutionTypes);
using BoundaryTypes = GetPropType<TypeTag, Properties::BoundaryTypes>;
using SolutionTypes = GetProp<TypeTag, Properties::SolutionTypes>;
using PrimaryVariables = typename SolutionTypes::PrimaryVariables;
using CellData = typename GET_PROP_TYPE(TypeTag, CellData);
using CellData = GetPropType<TypeTag, Properties::CellData>;
using Element = typename GridView::Traits::template Codim<0>::Entity;
using Intersection = typename GridView::Intersection;
......
......@@ -32,7 +32,8 @@
namespace Dumux {
namespace Properties {
SET_TYPE_PROP(PressureOneP, Model, typename GET_PROP_TYPE(TypeTag, PressureModel));
template<class TypeTag>
struct Model<TypeTag, TTag::PressureOneP> { using type = GetPropType<TypeTag, Properties::PressureModel>; };
}
/*!
* \ingroup SequentialOnePModel
......@@ -43,17 +44,17 @@ SET_TYPE_PROP(PressureOneP, Model, typename GET_PROP_TYPE(TypeTag, PressureModel
template<class TypeTag>
class DiffusionProblem1P: public OneModelProblem<TypeTag>
{
using Implementation = typename GET_PROP_TYPE(TypeTag, Problem);
using Implementation = GetPropType<TypeTag, Properties::Problem>;
using ParentType = OneModelProblem<TypeTag>;
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using GridView = GetPropType<TypeTag, Properties::GridView>;
using Grid = typename GridView::Grid;
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using TimeManager = typename GET_PROP_TYPE(TypeTag, TimeManager);
using TimeManager = GetPropType<TypeTag, Properties::TimeManager>;
// material properties
using SpatialParams = typename GET_PROP_TYPE(TypeTag, SpatialParams);
using SpatialParams = GetPropType<TypeTag, Properties::SpatialParams>;
using Element = typename GridView::Traits::template Codim<0>::Entity;
......
......@@ -38,7 +38,10 @@ namespace Properties {
//////////////////////////////////////////////////////////////////
//! The type tag for 1p pressure models
NEW_TYPE_TAG(PressureOneP, INHERITS_FROM(Pressure, SequentialOneP));
// Create new type tags
namespace TTag {
struct PressureOneP { using InheritsFrom = std::tuple<SequentialOneP, Pressure>; };
} // end namespace TTag
//////////////////////////////////////////////////////////////////
// Property tags
......
......@@ -41,8 +41,8 @@ template<class TypeTag>
class FluxData1P
{
private:
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using GridView = GetPropType<TypeTag, Properties::GridView>;
enum
{
......
......@@ -47,12 +47,16 @@ namespace Properties {
//////////////////////////////////////////////////////////////////
//! The type tag for the single-phase problem
NEW_TYPE_TAG(SequentialOneP, INHERITS_FROM(SequentialModel));
// Create new type tags
namespace TTag {
struct SequentialOneP { using InheritsFrom = std::tuple<SequentialModel>; };
} // end namespace TTag
//////////////////////////////////////////////////////////////////
// Property tags
//////////////////////////////////////////////////////////////////
NEW_PROP_TAG( Fluid ); // The fluid for one-phase models
template<class TypeTag, class MyTypeTag>
struct Fluid { using type = UndefinedProperty; }; // The fluid for one-phase models
} // end namespace Properties
} // end namespace Dumux
......@@ -68,25 +72,32 @@ namespace Properties {
//////////////////////////////////////////////////////////////////
//! Set number of equations to 1 for isothermal one-phase models
SET_INT_PROP(SequentialOneP, NumEq, 1);
template<class TypeTag>
struct NumEq<TypeTag, TTag::SequentialOneP> { static constexpr int value = 1; };
//! Set number of phases to 1 for one-phase models
SET_INT_PROP(SequentialOneP, NumPhases, 1);
template<class TypeTag>
struct NumPhases<TypeTag, TTag::SequentialOneP> { static constexpr int value = 1; };
//! Each phase consists of 1 pure component
SET_INT_PROP(SequentialOneP, NumComponents, 1);
template<class TypeTag>
struct NumComponents<TypeTag, TTag::SequentialOneP> { static constexpr int value = 1; };
//! Chose the set of indices for the one-phase formulation
SET_TYPE_PROP(SequentialOneP, Indices, SequentialOnePCommonIndices);
template<class TypeTag>
struct Indices<TypeTag, TTag::SequentialOneP> { using type = SequentialOnePCommonIndices; };
//! Set general sequential VariableClass as default
SET_TYPE_PROP(SequentialOneP, Variables, VariableClass<TypeTag>);
template<class TypeTag>
struct Variables<TypeTag, TTag::SequentialOneP> { using type = VariableClass<TypeTag>; };
//! Set standart CellData of immiscible one-phase models as default
SET_TYPE_PROP(SequentialOneP, CellData, CellData1P<TypeTag>);
template<class TypeTag>
struct CellData<TypeTag, TTag::SequentialOneP> { using type = CellData1P<TypeTag>; };
//! The spatial parameters to be employed. Use BoxSpatialParams by default.
SET_TYPE_PROP(SequentialOneP, SpatialParams, SequentialFVSpatialParamsOneP<TypeTag>);
template<class TypeTag>
struct SpatialParams<TypeTag, TTag::SequentialOneP> { using type = SequentialFVSpatialParamsOneP<TypeTag>; };
} // end namespace Properties
} // end namespace Dumux
#endif
......@@ -62,17 +62,17 @@ template<class TypeTag>
class CellData2P<TypeTag, false>
{
private:
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using GridView = GetPropType<TypeTag, Properties::GridView>;
using FluxData = FluxData2P<TypeTag>;
using FluidState = typename GET_PROP_TYPE(TypeTag, FluidState);
using FluidState = GetPropType<TypeTag, Properties::FluidState>;
enum
{
dim = GridView::dimension, dimWorld = GridView::dimensionworld
};
using Indices = typename GET_PROP_TYPE(TypeTag, ModelTraits)::Indices;
using Indices = typename GetPropType<TypeTag, Properties::ModelTraits>::Indices;
enum
{
......@@ -80,7 +80,7 @@ private:
};
enum
{
numPhases = GET_PROP_VALUE(TypeTag, NumPhases)
numPhases = getPropValue<TypeTag, Properties::NumPhases>()
};
private:
Scalar saturation_[numPhases];
......@@ -404,17 +404,17 @@ template<class TypeTag>
class CellData2P<TypeTag, true>
{
private:
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using GridView = GetPropType<TypeTag, Properties::GridView>;
using FluxData = FluxData2P<TypeTag>;
using FluidState = typename GET_PROP_TYPE(TypeTag, FluidState);
using FluidState = GetPropType<TypeTag, Properties::FluidState>;
enum
{
dim = GridView::dimension, dimWorld = GridView::dimensionworld
};
using Indices = typename GET_PROP_TYPE(TypeTag, ModelTraits)::Indices;
using Indices = typename GetPropType<TypeTag, Properties::ModelTraits>::Indices;
enum
{
......@@ -422,7 +422,7 @@ private:
};
enum
{
numPhases = GET_PROP_VALUE(TypeTag, NumPhases)
numPhases = getPropValue<TypeTag, Properties::NumPhases>()
};
private:
Scalar potential_[numPhases];
......
......@@ -38,18 +38,18 @@ namespace Dumux {
* \tparam TypeTag The problem TypeTag
* \tparam bool Used for specialization for case of compressible flow (<tt>true</tt>) or incompressible flow (<tt>false</tt>)
*/
template<class TypeTag, bool enableCompressibility = GET_PROP_VALUE(TypeTag, EnableCompressibility)>
template<class TypeTag, bool enableCompressibility = getPropValue<TypeTag, Properties::EnableCompressibility>()>
class CellData2PAdaptive: public CellData2P<TypeTag, enableCompressibility>
{
private:
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using GridView = GetPropType<TypeTag, Properties::GridView>;
using Grid = typename GridView::Grid;
using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
using Problem = GetPropType<TypeTag, Properties::Problem>;
using Element = typename GridView::Traits::template Codim<0>::Entity;
using Indices = typename GET_PROP_TYPE(TypeTag, ModelTraits)::Indices;
using Indices = typename GetPropType<TypeTag, Properties::ModelTraits>::Indices;
enum
{
......
......@@ -114,25 +114,25 @@ template<class TypeTag> class FVPressure2P: public FVPressure<TypeTag>
using ParentType = FVPressure<TypeTag>;
//the model implementation
using Implementation = typename GET_PROP_TYPE(TypeTag, PressureModel);
using Implementation = GetPropType<TypeTag, Properties::PressureModel>;
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
using GridView = GetPropType<TypeTag, Properties::GridView>;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using Problem = GetPropType<TypeTag, Properties::Problem>;
using SpatialParams = typename GET_PROP_TYPE(TypeTag, SpatialParams);
using SpatialParams = GetPropType<TypeTag, Properties::SpatialParams>;
using MaterialLaw = typename SpatialParams::MaterialLaw;
using Indices = typename GET_PROP_TYPE(TypeTag, ModelTraits)::Indices;
using Indices = typename GetPropType<TypeTag, Properties::ModelTraits>::Indices;
using FluidSystem = typename GET_PROP_TYPE(TypeTag, FluidSystem);
using FluidState = typename GET_PROP_TYPE(TypeTag, FluidState);
using FluidSystem = GetPropType<TypeTag, Properties::FluidSystem>;
using FluidState = GetPropType<TypeTag, Properties::FluidState>;
using BoundaryTypes = typename GET_PROP_TYPE(TypeTag, BoundaryTypes);
using SolutionTypes = typename GET_PROP(TypeTag, SolutionTypes);
using BoundaryTypes = GetPropType<TypeTag, Properties::BoundaryTypes>;
using SolutionTypes = GetProp<TypeTag, Properties::SolutionTypes>;
using PrimaryVariables = typename SolutionTypes::PrimaryVariables;
using CellData = typename GET_PROP_TYPE(TypeTag, CellData);
using PressureSolutionVector = typename GET_PROP_TYPE(TypeTag, PressureSolutionVector);
using CellData = GetPropType<TypeTag, Properties::CellData>;
using PressureSolutionVector = GetPropType<TypeTag, Properties::PressureSolutionVector>;
using ScalarSolutionType = typename SolutionTypes::ScalarSolution;
......@@ -154,7 +154,7 @@ template<class TypeTag> class FVPressure2P: public FVPressure<TypeTag>
};
enum
{
wPhaseIdx = Indices::wPhaseIdx, nPhaseIdx = Indices::nPhaseIdx, numPhases = GET_PROP_VALUE(TypeTag, NumPhases)
wPhaseIdx = Indices::wPhaseIdx, nPhaseIdx = Indices::nPhaseIdx, numPhases = getPropValue<TypeTag, Properties::NumPhases>()
};
using Element = typename GridView::Traits::template Codim<0>::Entity;
......@@ -594,11 +594,11 @@ private:
int vtkOutputLevel_;
static const bool compressibility_ = GET_PROP_VALUE(TypeTag, EnableCompressibility);
static const bool compressibility_ = getPropValue<TypeTag, Properties::EnableCompressibility>();
//! Gives kind of pressure used (\f$p_w\f$, \f$p_n\f$, \f$p_{global}\f$)
static const int pressureType_ = GET_PROP_VALUE(TypeTag, PressureFormulation);
static const int pressureType_ = getPropValue<TypeTag, Properties::PressureFormulation>();
//! Gives kind of saturation used (\f$S_w\f$, \f$S_n\f$)
static const int saturationType_ = GET_PROP_VALUE(TypeTag, SaturationFormulation);
static const int saturationType_ = getPropValue<TypeTag, Properties::SaturationFormulation>();
};
/*!
......
......@@ -45,18 +45,18 @@ template<class TypeTag> class FVPressure2PAdaptive: public FVPressure2P<TypeTag>
{
using ParentType = FVPressure2P<TypeTag>;
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
using GridView = GetPropType<TypeTag, Properties::GridView>;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using Problem = GetPropType<TypeTag, Properties::Problem>;
using Indices = typename GET_PROP_TYPE(TypeTag, ModelTraits)::Indices;
using Indices = typename GetPropType<TypeTag, Properties::ModelTraits>::Indices;
using FluidSystem = typename GET_PROP_TYPE(TypeTag, FluidSystem);
using FluidState = typename GET_PROP_TYPE(TypeTag, FluidState);
using FluidSystem = GetPropType<TypeTag, Properties::FluidSystem>;
using FluidState = GetPropType<TypeTag, Properties::FluidState>;
using SolutionTypes = typename GET_PROP(TypeTag, SolutionTypes);
using SolutionTypes = GetProp<TypeTag, Properties::SolutionTypes>;
using PrimaryVariables = typename SolutionTypes::PrimaryVariables;
using CellData = typename GET_PROP_TYPE(TypeTag, CellData);
using CellData = GetPropType<TypeTag, Properties::CellData>;
enum
{
......@@ -72,7 +72,7 @@ template<class TypeTag> class FVPressure2PAdaptive: public FVPressure2P<TypeTag>
};
enum
{
wPhaseIdx = Indices::wPhaseIdx, nPhaseIdx = Indices::nPhaseIdx, numPhases = GET_PROP_VALUE(TypeTag, NumPhases)
wPhaseIdx = Indices::wPhaseIdx, nPhaseIdx = Indices::nPhaseIdx, numPhases = getPropValue<TypeTag, Properties::NumPhases>()
};
using Intersection = typename GridView::Intersection;
......@@ -231,17 +231,17 @@ public:
private:
Problem& problem_;
FVVelocity<TypeTag, typename GET_PROP_TYPE(TypeTag, Velocity)> velocity_;
FVVelocity<TypeTag, GetPropType<TypeTag, Properties::Velocity>> velocity_;
const GravityVector& gravity_; //!< vector including the gravity constant
Scalar density_[numPhases];
Scalar viscosity_[numPhases];
static const bool compressibility_ = GET_PROP_VALUE(TypeTag, EnableCompressibility);
static const bool compressibility_ = getPropValue<TypeTag, Properties::EnableCompressibility>();
//! gives kind of pressure used (\f$p_w\f$, \f$p_n\f$, \f$p_{global}\f$)
static const int pressureType_ = GET_PROP_VALUE(TypeTag, PressureFormulation);
static const int pressureType_ = getPropValue<TypeTag, Properties::PressureFormulation>();
//! gives kind of saturation used (\f$S_w\f$, \f$S_n\f$)
static const int saturationType_ = GET_PROP_VALUE(TypeTag, SaturationFormulation);
static const int saturationType_ = getPropValue<TypeTag, Properties::SaturationFormulation>();
};
/*!
......@@ -264,7 +264,7 @@ void FVPressure2PAdaptive<TypeTag>::getFlux(EntryType& entry, const Intersection
ParentType::getFlux(entry, intersection, cellData, first);
// add the entry only once in case the VisitFacesOnlyOnce option is enabled!!!
if (GET_PROP_VALUE(TypeTag, VisitFacesOnlyOnce) && elementI.level() < elementJ.level())
if (getPropValue<TypeTag, Properties::VisitFacesOnlyOnce>() && elementI.level() < elementJ.level())
{
entry = 0.;
}
......
......@@ -25,7 +25,7 @@
#define DUMUX_FVPRESSUREPORPERTIES2P_SEQUENTIAL_HH
//Dumux-includes
#include <dumux/common/properties/propertysystemmacros.hh>
#include <dumux/common/properties.hh>
#include <dumux/porousmediumflow/2p/sequential/diffusion/properties.hh>
namespace Dumux {
......@@ -43,7 +43,10 @@ namespace Properties {
//////////////////////////////////////////////////////////////////
//! The type tag for two-phase problems using a standard finite volume model
NEW_TYPE_TAG(FVPressureTwoP, INHERITS_FROM(PressureTwoP));
// Create new type tags
namespace TTag {
struct FVPressureTwoP { using InheritsFrom = std::tuple<PressureTwoP>; };
} // end namespace TTag
//////////////////////////////////////////////////////////////////
// Property tags
......@@ -61,11 +64,14 @@ namespace Properties {
// Properties
//////////////////////////////////////////////////////////////////
//! Set velocity reconstruction implementation standard cell centered finite volume schemes as default
SET_TYPE_PROP( FVPressureTwoP, Velocity, FVVelocity2P<TypeTag> );
template<class TypeTag>
struct Velocity<TypeTag, TTag:: FVPressureTwoP> { using type = FVVelocity2P<TypeTag> ; };
//! Set finite volume implementation of the two-phase pressure equation as default pressure model
SET_TYPE_PROP(FVPressureTwoP, PressureModel, FVPressure2P<TypeTag>);
template<class TypeTag>
struct PressureModel<TypeTag, TTag::FVPressureTwoP> { using type = FVPressure2P<TypeTag>; };
//! Allow assembling algorithm for the pressure matrix to assemble only from one side of a cell-cell interface
SET_BOOL_PROP(FVPressureTwoP, VisitFacesOnlyOnce, true);
template<class TypeTag>
struct VisitFacesOnlyOnce<TypeTag, TTag::FVPressureTwoP> { static constexpr bool value = true; };
} // end namespace Properties
} // end namespace Dumux
......
......@@ -42,7 +42,10 @@ namespace Properties {
//////////////////////////////////////////////////////////////////
//! The type tag for two-phase problems using a grid-adaptive finite volume model
NEW_TYPE_TAG(FVPressureTwoPAdaptive, INHERITS_FROM(PressureTwoP));
// Create new type tags
namespace TTag {
struct FVPressureTwoPAdaptive { using InheritsFrom = std::tuple<PressureTwoP>; };
} // end namespace TTag
//////////////////////////////////////////////////////////////////
// Property tags
......@@ -61,11 +64,14 @@ namespace Properties {
//////////////////////////////////////////////////////////////////
//! Set velocity reconstruction implementation for grid-adaptive cell centered finite volume schemes as default
SET_TYPE_PROP( FVPressureTwoPAdaptive, Velocity, FVVelocity2PAdaptive<TypeTag> );
template<class TypeTag>
struct Velocity<TypeTag, TTag:: FVPressureTwoPAdaptive> { using type = FVVelocity2PAdaptive<TypeTag> ; };
//! Set finite volume implementation of the two-phase pressure equation which allows hanging nodes as default pressure model
SET_TYPE_PROP(FVPressureTwoPAdaptive, PressureModel, FVPressure2PAdaptive<TypeTag>);
template<class TypeTag>
struct PressureModel<TypeTag, TTag::FVPressureTwoPAdaptive> { using type = FVPressure2PAdaptive<TypeTag>; };
//! Allow assembling algorithm for the pressure matrix to assemble only from one side of a cell-cell interface
SET_BOOL_PROP(FVPressureTwoPAdaptive, VisitFacesOnlyOnce, true);
template<class TypeTag>
struct VisitFacesOnlyOnce<TypeTag, TTag::FVPressureTwoPAdaptive> { static constexpr bool value = true; };
} // end namespace Properties
} // end namespace Dumnux
......
......@@ -39,7 +39,7 @@ namespace Dumux {
template<class TypeTag> class FVPressureVelocity2P: public FVPressure2P<TypeTag>
{
using ParentType = FVPressure2P<TypeTag>;
using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
using Problem = GetPropType<TypeTag, Properties::Problem>;
public:
/*!
* \brief Initializes the pressure model
......@@ -88,7 +88,7 @@ public:
{}
private:
FVVelocity<TypeTag, typename GET_PROP_TYPE(TypeTag, Velocity) > velocity_;
FVVelocity<TypeTag, GetPropType<TypeTag, Properties::Velocity> > velocity_;
};
} // end namespace Dumux
......