changed: move the OutputDir parameter to Opm::Parameters

This commit is contained in:
Arne Morten Kvarving 2024-06-28 12:16:28 +02:00
parent 95841aaae2
commit da2b47b459
4 changed files with 13 additions and 12 deletions

View File

@ -237,10 +237,6 @@ struct MinTimeStepSize<TypeTag, TTag::FvBaseDiscretization>
static constexpr type value = 0.0;
};
//! By default, write the simulation output to the current working directory
template<class TypeTag>
struct OutputDir<TypeTag, TTag::FvBaseDiscretization> { static constexpr auto value = "."; };
//! Enable the VTK output by default
template<class TypeTag>
struct EnableVtkOutput<TypeTag, TTag::FvBaseDiscretization> { static constexpr bool value = true; };
@ -342,6 +338,11 @@ template<class TypeTag>
struct EnableGridAdaptation<TypeTag, Properties::TTag::FvBaseDiscretization>
{ static constexpr bool value = false; };
//! By default, write the simulation output to the current working directory
template<class TypeTag>
struct OutputDir<TypeTag, Properties::TTag::FvBaseDiscretization>
{ static constexpr auto value = "."; };
} // namespace Opm::Parameters
namespace Opm {
@ -527,7 +528,7 @@ public:
("Turn on caching of intensive quantities");
Parameters::registerParam<TypeTag, Properties::EnableStorageCache>
("Store previous storage terms and avoid re-calculating them.");
Parameters::registerParam<TypeTag, Properties::OutputDir>
Parameters::registerParam<TypeTag, Parameters::OutputDir>
("The directory to which result files are written");
}

View File

@ -46,6 +46,12 @@ struct ThreadsPerProcess { using type = Properties::UndefinedProperty; };
template<class TypeTag, class MyTypeTag>
struct EnableGridAdaptation { using type = Properties::UndefinedProperty; };
/*!
* \brief The directory to which simulation output ought to be written to.
*/
template<class TypeTag, class MyTypeTag>
struct OutputDir { using type = Properties::UndefinedProperty; };
} // namespace Opm::Parameters
#endif

View File

@ -204,7 +204,7 @@ public:
*/
std::string outputDir() const
{
std::string outputDir = Parameters::get<TypeTag, Properties::OutputDir>();
std::string outputDir = Parameters::get<TypeTag, Parameters::OutputDir>();
if (outputDir.empty())
outputDir = ".";

View File

@ -199,12 +199,6 @@ struct UseLinearizationLock { using type = UndefinedProperty; };
// high-level simulation control
/*!
* \brief The directory to which simulation output ought to be written to.
*/
template<class TypeTag, class MyTypeTag>
struct OutputDir { using type = UndefinedProperty; };
/*!
* \brief Global switch to enable or disable the writing of VTK output files
*