[cleanup] replace typedef by using

This commit is contained in:
Bernd Flemisch
2020-06-10 13:49:42 +02:00
parent bdb7bac3e8
commit d72de0f308
224 changed files with 2232 additions and 2240 deletions

View File

@@ -80,10 +80,10 @@ template<class TypeTag>
struct WettingPhase<TypeTag, TTag::PowerInjectionBaseProblem>
{
private:
typedef GetPropType<TypeTag, Properties::Scalar> Scalar;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
public:
typedef Opm::LiquidPhase<Scalar, Opm::SimpleH2O<Scalar> > type;
using type = Opm::LiquidPhase<Scalar, Opm::SimpleH2O<Scalar> >;
};
// Set the non-wetting phase
@@ -91,10 +91,10 @@ template<class TypeTag>
struct NonwettingPhase<TypeTag, TTag::PowerInjectionBaseProblem>
{
private:
typedef GetPropType<TypeTag, Properties::Scalar> Scalar;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
public:
typedef Opm::GasPhase<Scalar, Opm::Air<Scalar> > type;
using type = Opm::GasPhase<Scalar, Opm::Air<Scalar> >;
};
// Set the material Law
@@ -102,23 +102,22 @@ template<class TypeTag>
struct MaterialLaw<TypeTag, TTag::PowerInjectionBaseProblem>
{
private:
typedef GetPropType<TypeTag, Properties::FluidSystem> FluidSystem;
using FluidSystem = GetPropType<TypeTag, Properties::FluidSystem>;
enum { wettingPhaseIdx = FluidSystem::wettingPhaseIdx };
enum { nonWettingPhaseIdx = FluidSystem::nonWettingPhaseIdx };
typedef GetPropType<TypeTag, Properties::Scalar> Scalar;
typedef Opm::TwoPhaseMaterialTraits<Scalar,
/*wettingPhaseIdx=*/FluidSystem::wettingPhaseIdx,
/*nonWettingPhaseIdx=*/FluidSystem::nonWettingPhaseIdx>
Traits;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using Traits = Opm::TwoPhaseMaterialTraits<Scalar,
/*wettingPhaseIdx=*/FluidSystem::wettingPhaseIdx,
/*nonWettingPhaseIdx=*/FluidSystem::nonWettingPhaseIdx>;
// define the material law which is parameterized by effective
// saturations
typedef Opm::RegularizedVanGenuchten<Traits> EffectiveLaw;
using EffectiveLaw = Opm::RegularizedVanGenuchten<Traits>;
public:
// define the material law parameterized by absolute saturations
typedef Opm::EffToAbsLaw<EffectiveLaw> type;
using type = Opm::EffToAbsLaw<EffectiveLaw>;
};
// Write out the filter velocities for this problem
@@ -190,19 +189,19 @@ namespace Opm {
template <class TypeTag>
class PowerInjectionProblem : public GetPropType<TypeTag, Properties::BaseProblem>
{
typedef GetPropType<TypeTag, Properties::BaseProblem> ParentType;
using ParentType = GetPropType<TypeTag, Properties::BaseProblem>;
typedef GetPropType<TypeTag, Properties::Scalar> Scalar;
typedef GetPropType<TypeTag, Properties::GridView> GridView;
typedef GetPropType<TypeTag, Properties::Indices> Indices;
typedef GetPropType<TypeTag, Properties::FluidSystem> FluidSystem;
typedef GetPropType<TypeTag, Properties::WettingPhase> WettingPhase;
typedef GetPropType<TypeTag, Properties::NonwettingPhase> NonwettingPhase;
typedef GetPropType<TypeTag, Properties::PrimaryVariables> PrimaryVariables;
typedef GetPropType<TypeTag, Properties::EqVector> EqVector;
typedef GetPropType<TypeTag, Properties::RateVector> RateVector;
typedef GetPropType<TypeTag, Properties::BoundaryRateVector> BoundaryRateVector;
typedef GetPropType<TypeTag, Properties::Simulator> Simulator;
using Scalar = GetPropType<TypeTag, Properties::Scalar>;
using GridView = GetPropType<TypeTag, Properties::GridView>;
using Indices = GetPropType<TypeTag, Properties::Indices>;
using FluidSystem = GetPropType<TypeTag, Properties::FluidSystem>;
using WettingPhase = GetPropType<TypeTag, Properties::WettingPhase>;
using NonwettingPhase = GetPropType<TypeTag, Properties::NonwettingPhase>;
using PrimaryVariables = GetPropType<TypeTag, Properties::PrimaryVariables>;
using EqVector = GetPropType<TypeTag, Properties::EqVector>;
using RateVector = GetPropType<TypeTag, Properties::RateVector>;
using BoundaryRateVector = GetPropType<TypeTag, Properties::BoundaryRateVector>;
using Simulator = GetPropType<TypeTag, Properties::Simulator>;
enum {
// number of phases
@@ -220,13 +219,13 @@ class PowerInjectionProblem : public GetPropType<TypeTag, Properties::BaseProble
dimWorld = GridView::dimensionworld
};
typedef GetPropType<TypeTag, Properties::MaterialLaw> MaterialLaw;
typedef GetPropType<TypeTag, Properties::MaterialLawParams> MaterialLawParams;
using MaterialLaw = GetPropType<TypeTag, Properties::MaterialLaw>;
using MaterialLawParams = GetPropType<TypeTag, Properties::MaterialLawParams>;
typedef typename GridView::ctype CoordScalar;
typedef Dune::FieldVector<CoordScalar, dimWorld> GlobalPosition;
using CoordScalar = typename GridView::ctype;
using GlobalPosition = Dune::FieldVector<CoordScalar, dimWorld>;
typedef Dune::FieldMatrix<Scalar, dimWorld, dimWorld> DimMatrix;
using DimMatrix = Dune::FieldMatrix<Scalar, dimWorld, dimWorld>;
public:
/*!