changed: remove NEW_TYPE_TAG macro usage

This commit is contained in:
Arne Morten Kvarving
2020-08-27 10:30:29 +02:00
parent 914053ac3c
commit e8248b44ff
42 changed files with 213 additions and 56 deletions

View File

@@ -71,7 +71,12 @@
namespace Opm::Properties {
NEW_TYPE_TAG(EclFlowProblem, INHERITS_FROM(BlackOilModel, EclBaseProblem, FlowNonLinearSolver, FlowModelParameters, FlowTimeSteppingParameters));
namespace TTag {
struct EclFlowProblem {
using InheritsFrom = std::tuple<FlowTimeSteppingParameters, FlowModelParameters,
FlowNonLinearSolver, EclBaseProblem, BlackOilModel>;
};
}
SET_STRING_PROP(EclFlowProblem, OutputDir, "");
SET_BOOL_PROP(EclFlowProblem, EnableDebuggingChecks, false);
// default in flow is to formulate the equations in surface volumes

View File

@@ -27,7 +27,9 @@
namespace Opm::Properties {
NEW_TYPE_TAG(FlowModelParameters);
namespace TTag {
struct FlowModelParameters {};
}
NEW_PROP_TAG(DbhpMaxRel);
NEW_PROP_TAG(DwellFractionMax);

View File

@@ -69,7 +69,7 @@ namespace Opm
class FlowMainEbos
{
public:
typedef typename GET_PROP(TypeTag, MaterialLaw)::EclMaterialLawManager MaterialLawManager;
using MaterialLawManager = typename GetProp<TypeTag, Properties::MaterialLaw>::EclMaterialLawManager;
using EbosSimulator = GetPropType<TypeTag, Properties::Simulator>;
using Grid = GetPropType<TypeTag, Properties::Grid>;
using GridView = GetPropType<TypeTag, Properties::GridView>;
@@ -89,7 +89,7 @@ namespace Opm
// Read the command line parameters. Throws an exception if something goes wrong.
static int setupParameters_(int argc, char** argv)
{
using ParamsMeta = typename GET_PROP(TypeTag, ParameterMetaData);
using ParamsMeta = GetProp<TypeTag, Properties::ParameterMetaData>;
if (!ParamsMeta::registrationOpen()) {
// We have already successfully run setupParameters_().
// For the dynamically chosen runs (as from the main flow

View File

@@ -67,7 +67,11 @@ namespace Opm::Properties {
// this is a dummy type tag that is used to setup the parameters before the actual
// simulator.
NEW_TYPE_TAG(FlowEarlyBird, INHERITS_FROM(EclFlowProblem));
namespace TTag {
struct FlowEarlyBird {
using InheritsFrom = std::tuple<EclFlowProblem>;
};
}
} // namespace Opm::Properties

View File

@@ -36,7 +36,9 @@
namespace Opm::Properties {
NEW_TYPE_TAG(FlowNonLinearSolver);
namespace TTag {
struct FlowNonLinearSolver {};
}
NEW_PROP_TAG(NewtonMaxRelax);
NEW_PROP_TAG(FlowNewtonMaxIterations);

View File

@@ -41,7 +41,9 @@ class ISTLSolverEbos;
namespace Opm::Properties {
NEW_TYPE_TAG(FlowIstlSolverParams);
namespace TTag {
struct FlowIstlSolverParams {};
}
NEW_PROP_TAG(LinearSolverReduction);
NEW_PROP_TAG(IluRelaxation);

View File

@@ -56,7 +56,11 @@
namespace Opm::Properties {
NEW_TYPE_TAG(FlowIstlSolver, INHERITS_FROM(FlowIstlSolverParams));
namespace TTag {
struct FlowIstlSolver {
using InheritsFrom = std::tuple<FlowIstlSolverParams>;
};
}
template <class TypeTag, class MyTypeTag>
struct EclWellModel;

View File

@@ -35,7 +35,11 @@
namespace Opm::Properties {
NEW_TYPE_TAG(FlowIstlSolverFlexible, INHERITS_FROM(FlowIstlSolverParams));
namespace TTag {
struct FlowIstlSolverFlexible {
using InheritsFrom = std::tuple<FlowIstlSolverParams>;
};
}
} // namespace Opm::Properties

View File

@@ -19,7 +19,9 @@
namespace Opm::Properties {
NEW_TYPE_TAG(FlowTimeSteppingParameters);
namespace TTag {
struct FlowTimeSteppingParameters {};
}
NEW_PROP_TAG(SolverRestartFactor);
NEW_PROP_TAG(SolverGrowthFactor);